← All cores
Arcade-NMK16_Gunnail
Cites hardware documentation that MAME's driver does not — 10
- NMK16_Gunnail.sv:516 2026-09-13: the 27 Afega sets (ids 23-43) moved to their own NMK16_Afega.rbf, so this build leaves their YM2151 out of the netlist (INCLUDE_AFEGA(0)) and keeps everything else.
- rtl/gunnail/gunnail_core.sv:21 - The nine others: set_screen_lowres (384 x 278 at 6 MHz, visible 92..347 — the same 64 us line as the 512 x 8 MHz raster, so this core keeps its raster and draws a 256-px window at hcount 92..347), 32x32 TX tilemap, frame-constant scroll r
- rtl/gunnail/gunnail_core.sv:1954 Frame-constant scroll registers (every game but gunnail), in the board's own format (nmk16_v.cpp): scroll_w<Layer> (macross_map/acrobatm/tdragon/hachamf/strahl on the LOW byte of words 0x...0/2/4/6; bioship on the HIGH byte — umask16(0xff00
- rtl/gunnail/gunnail_core.sv:1970 Inferred from the code -- no schematic of this board; MAME drops these writes.
- rtl/gunnail/gunnail_core.sv:2183 mustang: 0x080018 D0 -> BG ROM A19 (one 74LS74); a 4 Mbit ROM ignores it, cfg_bga_mask wraps it the same way
- rtl/gunnail/gunnail_core.sv:2903 Unlike tharrier's own undumped/simulated MCU above, this bootleg's chip is fully dumped, so the game runs against the real thing: rtl/m68705/m68705_core.sv (jotego's jt6805 plus this project's peripheral wrapper), verified instruction-for-i
- rtl/m68705/m68705_core.sv:4 Used only by tharrierb (Task Force Harrier, Lettering bootleg): its "MCU" is a genuine, fully-dumped M68705R3 (mc68705r35.bin, the whole 0x1000-byte internal image — bootstrap ROM + option byte + interrupt vectors included), not an undumped
- rtl/m68705/m68705_core.sv:21 Address map (M68705R3, 12-bit bus, m6805_hmos_device::internal_map + m68705_device + m68705r_device): 0x00/01/02/03 port A/B/C/D data, 0x04/05/06 DDR A/B/C (port D has none — it is a dedicated INPUT-only port on this chip, matching tharrier
- rtl/nmk_irq/nmk_irq.sv:29 Verified via a live MAME debugger capture (breakpoints at mustang's own IRQ1-4 ISR entry addresses, resolved from the ROM's own autovector table, printing the debugger's `beamy` pseudo-symbol) against mustang's real, dumped V-PROM (`10.bpr`
- README.md:77 | `NMK16_Afega` | The Afega derivative boards: 12 MHz 68000 with address-scrambled program ROMs decoded per fetch, Z80 + YM2151 + OKI or twin-OKI sound, an 8bpp
Cites hardware references or measurements that MAME's driver also gives — 2
Says it was checked against the original PCB — 1
Notes where it differs from MAME — 4
- rtl/gunnail/gunnail_core.sv:3748 That is a MAME limitation rather than board behaviour, so the whole composed output is mirrored here exactly as for the other families -- a deliberate, documented divergence from MAME on Afega sprite pixels.
- rtl/tlcs90/nmk004_periph.sv:41 - Watchdog (WDMOD/WDCR), serial (SCMOD/SCCR/SCBUF — not even mapped for this specific TLCS-90 variant in the reference), ADC (ADREG/ADMOD), stepping-motor mode (SMMOD's *functional* effect, though the register itself is stored and read back
- rtl/tlcs90/tlcs90.sv:43 Still deferred: the TSET/LDA dead opcode space MAME's own reference model can't execute either — this is the CPU core's entire real opcode table, complete.
- README.md:100 | `tdragonb2` | *"runs too quickly, Oki sounds terrible (IRQ problems?)"* | Not attempted — it would mean diverging from MAME's own known-broken timing. |
Cites MAME source — 176
- NMK16_Gunnail.sv:1 NMK16 MiSTerFPGA project — real hardware top-level for the "Gunnail" RBF: GunNail (gunnail, gunnailp — nmk16.cpp gunnail_prot()) and, since 2026-09-11, the nine lowres NMK004 boards (macross, blkheart, mustang, bioship, vandyke, acrobatm, s
- NMK16_Gunnail.sv:6 Cloned from NMK16_Raphero.sv: the same framework wiring (hps_io, SDRAM, MAME-style keyboard, P1/P2 autofire, framebuffer rotation, .mra DIP capture) plus NMK16_Macross2.sv's video output retimer (here at 48 MHz: 8 MHz pixels for gunnail's 5
- NMK16_Gunnail.sv:64 A vertical (MAME ROT270) game drawn on its side by the board; the two "Vert" choices both present it upright through the framebuffer, as MAME does — "Vert 270" (the MAME-correct rotate_ccw direction) and "Vert 90" (the opposite quarter-turn
- NMK16_Gunnail.sv:189 MAME ORIENTATION_FLIP_Y sets (grdnstrm, grdnstrmau, firehawk, spec2kh): the board draws upside down for a monitor mounted that way; the picture is read out bottom-up (rd_y mirrored) so it displays upright, as MAME does.
- NMK16_Gunnail.sv:301 Keyboard: MAME's default key bindings, always active, ORed with the joysticks.
- NMK16_Gunnail.sv:304 P1: Up/Down/Left/Right arrows, B1 LCtrl, B2 LAlt, B3 Space, Start 1 P2: R/F/D/G, B1 A, B2 S, B3 Q, Start 2 Coin 1 = 5, Coin 2 = 6, Service (IPT_SERVICE1) = 9 Test / Service Mode = F2: a TOGGLE, as in MAME, flipping DSW1 SW1:8 (PORT_SERVICE_
- NMK16_Gunnail.sv:406 gunnail has no service-mode DIP (DSW1 bit 0 is Flip Screen); MAME's F2 maps to nothing here, so the DIP bytes pass straight through.
- NMK16_Gunnail.sv:609 Cheats (rtl/cheats.sv) — Pugsy's MAME cheat database, seven fixed slots with this game's addresses supplied by the .mra as <rom index="5">.
- NMK16_Gunnail.sv:640 This board has a third master -- the protection MCU -- and main RAM is its channel ("inc sprites, shared with MCU", nmk16.cpp hachamf_map).
- NMK16_Gunnail.sv:850 ROT270 in MAME: the board's image is turned counter-clockwise to stand upright, which is screen_rotate's rotate_ccw=1 case ("Vert 270"); "Vert 90" is rotate_ccw=0, the opposite quarter-turn, for cabinets whose vertical monitor is mounted th
- rtl/bjtwin/nmk_irq_hacky.sv:33 manybloc (nmk16.cpp manybloc_scanline + set_periodic_int, 2026-09-14): a different fixed table on a 240-line screen -- scanline 248 -> sprite DMA, then IRQ4 (both in the same callback, the memcpy first: vpos 248 is the line after the last
- rtl/bjtwin/video_timing.sv:7 Reset-time raster phase: `vcount` resets to `VACTIVE_END` (240, the first scanline of vblank), not 0 — confirmed directly against real MAME's own screen device (Family D bring-up investigation, tdragon1): `screen.vpos()` at machine time 0 s
- rtl/bjtwin/video_timing.sv:11 Measured two independent ways that agree: (1) a MAME Lua memory-read tap on the protection MCU's own P5 register (`screen.vpos()>>2`, the *exact* value real game code observes) showed vpos in [44,47] at real time 5.260ms after machine start
- rtl/bjtwin/video_timing.sv:41 MAME's manybloc_scanline fires off screen vpos, and vpos 0/248 line up with vcount 0/248 exactly under this window.
- rtl/cheats.sv:1 Cheat engine — applies Pugsy MAME-database pokes to work RAM once a frame.
- rtl/cheats.sv:23 Poke semantics follow MAME's "run" state: the value is written every frame for as long as the cheat is enabled, which is what makes "infinite" cheats hold against the game decrementing the counter.
- rtl/gunnail/gunnail_core.sv:14 What the boards are (nmk16.cpp, cross-checked per game): - gunnail: 68000 at 10 MHz, gunnail_map: I/O at 0x080000, palette 0x088000, gunnail_scrollram/scrollramy at 0x08C000/0x08C200 (write-only, 256 words each), BG VRAM 0x090000 (8192 word
- rtl/gunnail/gunnail_core.sv:51 - NMK-215 protection MCU (TMP90840, nmk_prot_core.sv, 8 KB ROM nmk-215.bin, byte-identical between gunnail and macross) at 4 MHz: it only loads the two NMK214 descrambler configs at boot through its port 3/port 7 (a MAME Lua trace over 30 s
- rtl/gunnail/gunnail_core.sv:112 Same-scene MAME comparison (2026-09-14, HW_ROMS=0 sim only, inert unless the files are given).
- rtl/gunnail/gunnail_core.sv:113 The attract demo drifts from MAME within a minute (NMK-7), so a late scene cannot be compared by frame index.
- rtl/gunnail/gunnail_core.sv:115 These load a MAME video-state dump straight into this core's own VRAM/palette arrays and hold the 68000 in reset, so the picture is rendered by the FULL core -- every per-game mux exactly as it ships -- rather than by a standalone video_mac
- rtl/gunnail/gunnail_core.sv:132 HW_ROMS=0 only: 1 = the DIP switches come from dsw1_i/dsw2_i (the testbench drives the .mra defaults, so the MAME comparison covers language/demo-sound dependent screens); 0 = 0xFFFF as before.
- rtl/gunnail/gunnail_core.sv:266 per-source audio taps (sim level checks against MAME's routes)
- rtl/gunnail/gunnail_core.sv:301 pixel readback (mirrors MAME's screen:pixel(x,y))
- rtl/gunnail/gunnail_core.sv:394 Every per-game difference is a function of game_sel; the values are transcribed from nmk16.cpp's machine configs, memory maps, GFXDECODE tables and ROM_START blocks (see the header).
- rtl/gunnail/gunnail_core.sv:427 2026-09-13: the Afega boards (Family H, afega_state in nmk16.cpp): 12 MHz 68000 on afega_map (16-bit DSW at +4, four scroll words at 0x084000/0x08C000, 768-entry palette, main RAM mirrored at 0x0C0000 and 0x0F0000), fixed-scanline IRQs, a Z
- rtl/gunnail/gunnail_core.sv:516 decode_ssmissin() is decode_tdragonb's GFX half and nothing else -- nmk16.cpp calls it "Like Thunder Dragon Bootleg without the Program Rom Swapping", and its table is byte-identical to decode_data_tdragonbgfx: {7,6,5,3,4,2,1,0}, i.e. bits
- rtl/gunnail/gunnail_core.sv:589 Memory maps (nmk16.cpp): the decode function below keys on these.
- rtl/gunnail/gunnail_core.sv:1256 Afega's decryptcode(): the program ROM is stored with address bits 17..13 permuted — MAME un-permutes the image once at init, this core permutes the 68000's address on every fetch instead (the .mra streams the raw files).
- rtl/gunnail/gunnail_core.sv:1259 Table t: the SOURCE bit for each of dest bits 17..13, i.e. RAM[i] = file[src] with src[17:13] = {i[a17], i[a16], i[a15], i[a14], i[a13]} (bitswap<24>'s argument order, nmk16.cpp).
- rtl/gunnail/gunnail_core.sv:1281 tdragonb (decode_tdragonb, nmk16.cpp): every program word is bitswapped — decode_word's table {e,c,a,8,7,5,3,1,f,d,b,9,6,4,2,0} gives dest bit (15-i) = src bit table[i].
- rtl/gunnail/gunnail_core.sv:1323 16 pairs + next-pair prefetch instead of rom_cache1's single pair: see rtl/rom_cache_n.sv (68000 slowdown vs MAME).
- rtl/gunnail/gunnail_core.sv:1619 MAME video-state injection (see the STATE_* parameters).
- rtl/gunnail/gunnail_core.sv:1764 ssmissin itself never uses the mirror, but airattck/airattcka (the same map and game id) write through it EXCLUSIVELY -- 4096 of 4096 writes measured in MAME -- so without this their TX layer is entirely lost.
- rtl/gunnail/gunnail_core.sv:1891 MAME keeps the whole 4 KB as plain .ram() and re-derives the BG scroll from two fixed words of it on EVERY write to the region (manybloc_scroll_w): 0x82/2 = word 0x41 is scrollx, 0xc2/2 = word 0x61 is scrolly.
- rtl/gunnail/gunnail_core.sv:1954 Frame-constant scroll registers (every game but gunnail), in the board's own format (nmk16_v.cpp): scroll_w<Layer> (macross_map/acrobatm/tdragon/hachamf/strahl on the LOW byte of words 0x...0/2/4/6; bioship on the HIGH byte — umask16(0xff00
- rtl/gunnail/gunnail_core.sv:1965 MAME decodes data[15:8] == 0/1 and has no y. mustangb3 (Lettering bootleg): one write per frame of 0x9000 | x (move.w $f90f2,d0 / ori.w #$9000,d0 at 0x62A-0x642, the variable the original splits into the index-0/1 pair): data[15:12] == 9 lo
- rtl/gunnail/gunnail_core.sv:1970 Inferred from the code -- no schematic of this board; MAME drops these writes.
- rtl/gunnail/gunnail_core.sv:2048 The screen_update variants read them differently (nmk16_v.cpp video_update / redhawki_video_update / screen_update_firehawk): see afega_vid.
- rtl/gunnail/gunnail_core.sv:2196 bioship ROM-tilemap DMA (2026-09-11): MAME's bioship_get_bg_tile_info reads the tile index from the "tilerom" region at (bank << 13) | tile_index on every tile fetch.
- rtl/gunnail/gunnail_core.sv:2472 jt03 uses jt49's YM2203 volume table (COMP 5); FM and SSG are mixed below at MAME's routes (tdragon2_core.sv has the story).
- rtl/gunnail/gunnail_core.sv:2687 x 3/2 (was 3/8 -- measured 8-13dB quiet vs MAME's real OKI:FM balance)
- rtl/gunnail/gunnail_core.sv:2690 jt51's left/right averaged; the OKI's 14-bit `sound` x 2.75 (~0.7 of the 16-bit scale MAME's stream has).
- rtl/gunnail/gunnail_core.sv:2700 x3: the Seibu boards' OKI (route 0.40) measured ~6 dB low at x3/2 on the board (mustangb/acrobatmbl vs MAME)
- rtl/gunnail/gunnail_core.sv:2707 YM2203 FM + SSG: MAME routes FM 1.20 and each SSG channel 0.50 at a 16382 full scale = 255 x 26.8 FM units -> x27.
- rtl/gunnail/gunnail_core.sv:2715 no FM chip on this board at all: the single OKI alone, at its own 1.0 MAME route
- rtl/gunnail/gunnail_core.sv:2746 The firmware is now read back from SDRAM after reset — 8/16 KB over the port-3 arbiter, ~2.5 ms at most — with the 68000 and the MCU held in reset until it is in; the NMK004 boots meanwhile and just waits for its first command, as it does i
- rtl/gunnail/gunnail_core.sv:2869 tharrier_map reads IN0 active HIGH, IN1 through the (undumped) MCU — word reads return ~IN1 (start/coin bits, active high on the bus), byte reads of the upper byte return a 15-entry sequence (tharrier_mcu_r), except at two program counters
- rtl/gunnail/gunnail_core.sv:2883 NMK-23b: this concatenation was 17 bits wide assigned to a 16-bit wire (verilator WIDTHTRUNC), so the MSB was dropped and every field above it sat one bit too high -- IPT_START2 "in game" landed on bit 9 instead of MAME's 0x0100 (bit 8), so
- rtl/gunnail/gunnail_core.sv:2894 Check code at 0x005640") that MAME leaves idle-high, so the port is the constant 0x8000.
- rtl/gunnail/gunnail_core.sv:2990 Protection?"): MAME keys on m_maincpu->pc() == 0x416 / 0x64E — the address AFTER the reading instruction (move.w $80006,D0 at 0x410 / 0x648, six bytes each; the boot loops there until the word equals ROM $640 = 0x9000, then ROM $3E7C = 0x54
- rtl/gunnail/gunnail_core.sv:3002 Family E (2026-09-14) protection reads and the acrobatmbl ROM patch: tdragonb_prot_r: 0x044022 reads 0x0003 ("no sprites without this"); tdragonb3: that read is unmapped (MAME's unmap value 0) and 0x060000-0x060021 read 0x00EE ("no sprites
- rtl/gunnail/gunnail_core.sv:3044 Family E (2026-09-14): the Seibu Sound System board (seibu_sound_map: ROM 0000-1FFF, RAM 2000-27FF, the seibu_sound register block at 4000-401F (rtl/seibu/seibu_sound.sv: latches, IM0 vector arbitration RST10 = YM3812 / RST18 = the 68000's
- rtl/gunnail/gunnail_core.sv:3190 The data lanes are captured through the 68000's write cycle (each lane as its strobe says, the other keeps its previous value: MAME's mem_mask) and handed over as a one-clock strobe on the cycle's trailing edge — a level would re-assert RST
- rtl/gunnail/gunnail_core.sv:3356 unmapped ports read 0 (MAME's unmap value): gunnailb's Air Buster driver spins at 0x528 until port 4 (its absent OKI, noprw) reads no busy channel
- rtl/gunnail/gunnail_core.sv:3386 cactus (2026-09-12): sabotenb's scrambled ROM data on a board with no NMK-215 — MAME's init_nmk table decode is the NMK214 scheme with the configs the NMK-215 sends sabotenb; they are written here after reset instead (the same two-byte sequ
- rtl/gunnail/gunnail_core.sv:3593 vandykeb_r: 0; tharrier: soundlatch2; comad boards have no NMK004 there -- twinactn_map noprw()s 0x08000E-F and ssmissin_map leaves it out entirely, both reading 0 in MAME
- rtl/gunnail/gunnail_core.sv:3610 MAME's unmap value for a 68000 program space is 0, but this core has always returned 0xFFFF and no shipped game noticed -- they do not read unmapped addresses.
- rtl/gunnail/gunnail_core.sv:3612 airattcka does: it reads 0x0C000C (unmapped in ssmissin_map, MAME returns 0x0000) during boot, and on 0xFFFF it computes a bad jump target and spins in unmapped space at PC 0x5F0C56 forever -- a black screen from frame ~50 on.
- rtl/gunnail/gunnail_core.sv:3706 The games read their Flip Screen DIP and write bit 0 of the flipscreen register (nmk16_v.cpp flipscreen_w -> flip_screen_set + m_spritegen->set_flip_screen); the register was being latched here and then ignored, so the DIP did nothing on an
- rtl/gunnail/gunnail_core.sv:3710 MAME flips the tilemaps and mirrors the sprite coordinates internally, but for a full-screen window the net result is exactly a 180-degree rotation of the visible area -- measured, not assumed: tdragon2 frame 600 with the DIP on is bit-iden
- rtl/gunnail/gunnail_core.sv:3715 So the readback coordinates are mirrored here, which reproduces MAME by construction and leaves the tilemap/sprite/prefetch pipeline alone.
- rtl/gunnail/gunnail_core.sv:3745 MAME flips only the tilemaps on these boards and leaves the sprites unmirrored ("flip-screen doesn't work on sprites for all sets" on the grdnstrm GAME line, ~5-9k sprite pixels out of place in a frame diff).
- rtl/m68705/m68705_core.sv:4 Used only by tharrierb (Task Force Harrier, Lettering bootleg): its "MCU" is a genuine, fully-dumped M68705R3 (mc68705r35.bin, the whole 0x1000-byte internal image — bootstrap ROM + option byte + interrupt vectors included), not an undumped
- rtl/m68705/m68705_core.sv:21 Address map (M68705R3, 12-bit bus, m6805_hmos_device::internal_map + m68705_device + m68705r_device): 0x00/01/02/03 port A/B/C/D data, 0x04/05/06 DDR A/B/C (port D has none — it is a dedicated INPUT-only port on this chip, matching tharrier
- rtl/m68705/m68705_core.sv:42 `cen_e` (pulsing once per real bus cycle, cen/4 — matching jt680x's own "crystal = 4x E" convention) drives it once per cycle rather than MAME's own once-per-instruction bulk credit; mathematically identical for this purely-linear prescale/
- rtl/m68705/m68705_core.sv:98 Cleared when the vector at 0x0FFA is fetched, which is the RTL's observable equivalent of MAME's interrupt() clearing the bit.
- rtl/m68705/m68705_core.sv:120 Simulation only: an INSTRUCTION trace, directly comparable with a MAME m6805 trace.
- rtl/m68705/m68705_core.sv:121 jt6805's `ni` microinstruction starts the next instruction with its opcode already in md and PC on that instruction, which is exactly what MAME's trace line shows.
- rtl/macross2/video_macross2.sv:2 Confirmed directly from the reference: `VIDEO_START_MEMBER(nmk16_state,macross2)` (nmk16_v.cpp:150-162) creates a `common_get_bg_tile_info<0,1>`-driven, `tilemap_scan_pages`-mapped, 256x32-tile (16x16 px) BG tilemap — the SAME BG geometry `
- rtl/macross2/video_macross2.sv:16 **No NMK214 descrambling** — macross2 has no protection MCU at all (`init_banked_audiocpu` only, nmk16.cpp:10736); bgtile/sprites ROM data is read directly, unlike video_macross.sv's own two live nmk214 instances.
- rtl/macross2/video_macross2.sv:20 **5-bit sprite colour, not 4** — `macross2()`'s own machine config uses `get_colour_5bit` (nmk16.cpp:5457, `colour &= 0x1f`), not `get_colour_4bit` every single prior port in this project has used.
- rtl/macross2/video_macross2.sv:23 `gfx_macross2`'s own GFXDECODE_START (nmk16.cpp:4194-4198) confirms the palette layout this requires: sprites at colour base `0x100` with **32** colours (`0x100-0x2FF`, matching the 5-bit index exactly), NOT `0x200` like macross's/gunnail's
- rtl/macross2/video_macross2.sv:34 Per-scanline raster scroll: macross2/tdragon2 (RASTER_SCROLL=0) have a single `scroll_w<0>` register (nmk16.cpp:1094) — `bg_xscroll`/ `bg_yscroll` below are frame-constant register inputs.
- rtl/macross2/video_macross2.sv:36 raphero (RASTER_SCROLL=1, VIDEO_START gunnail) instead has the two 256-word tables gunnail_scrollram/scrollramy, applied per bitmap line by nmk16_v.cpp bg_update(): for bitmap line y (16..239, i == y1 there), yscroll = scrollramy[0] + scrol
- rtl/macross2/video_macross2.sv:76 Sizes the sim array and the tile-code wrap (MAME draws code % elements, elements = bytes/128); the powerins mode's 16-bit code never wraps.
- rtl/macross2/video_macross2.sv:86 NMK214=1: BG bytes and sprite words pass through the two NMK214 descramblers (nmk16.cpp base_nmk214_215), configured by the protection MCU through nmk214_cfg_we/data.
- rtl/macross2/video_macross2.sv:148 HW_ROMS=1: 1 = the sprite region streams in ROM_LOAD16_WORD_SWAP (or odd-chip-first byte-pair) order, so the byte cache inverts address bit 0 (see the sprite cache comment); 0 = a plain ROM_LOAD byte ROM in MAME's own order (bioship, strahl
- rtl/macross2/video_macross2.sv:192 1 = every tile byte's nibbles are swapped (MAME's *_packed_lsb layouts: gfx_powerinsc).
- rtl/macross2/video_macross2.sv:196 Afega boards (2026-09-13, Family H on the Gunnail rbf): bg_8bpp: the BG is MAME's tilelayout_8bpp — the ROM region's two halves each hold a col_2x2_group 4bpp tile; MAME's decoder puts plane 0 in the pixel's MSB, so the FIRST half is the hi
- rtl/macross2/video_macross2.sv:207 bg_code_mod12k: the 8bpp region holds 12288 tiles per half (a 3 MB region: bubl2000) — MAME's gfx element indexing wraps the code modulo the element count, which a power-of-two mask cannot do.
- rtl/macross2/video_macross2.sv:214 Family E bootlegs (2026-09-14, Gunnail rbf): static byte bitswaps MAME applies to the raw GFX ROMs once at init, applied here to every fetched tile byte before the nibble extraction instead (the .mra streams the raw files): gfx_swap34 = dec
- rtl/macross2/video_macross2.sv:261 The real board's sprite DMA holds the 68000 off the bus for the ~200us the copy takes; MAME copies the whole table in an instant.
- rtl/macross2/video_macross2.sv:276 bgvideoram_w<Layer>/scroll_w<Layer> (nmk16.cpp:465-503): macross2's own bgvideoram is FOUR "banks" of the same 8192-tile-position tilemap (0x10000 bytes vs. every other port's own 0x4000 — see module header), selected by bits[5:4] of the sc
- rtl/macross2/video_macross2.sv:318 pixel readback for the testbench (mirrors MAME's screen:pixel(x,y))
- rtl/macross2/video_macross2.sv:331 set_scrolldx(28+64,28+64) and the sprite generator's videoshift(28+64) — both in MAME BITMAP coordinates, see BITMAP_X0 below
- rtl/macross2/video_macross2.sv:332 MAME positions tilemaps and sprites in BITMAP coordinates: the bitmap spans the whole raster (512x278) and the visible area starts at bitmap (28,16) — the hblank/vblank widths.
- rtl/macross2/video_macross2.sv:334 scrolldx(92) therefore means tilemap x = bitmap_x - 92 + scrollx = screen_x + 28 - 92 + scrollx (hence MAME's own "leftmost 64 pixels have to be retrieved from the other side" comment), tilemap y = screen_y + 16 + scrolly, and a sprite at X
- rtl/macross2/video_macross2.sv:350 MAME set_screen_midres (nmk16.cpp): raw 448 x 278 at 7 MHz, visible x 60..379 (320 px) — bitmap origin (60,16), the same 64 us line as the 512 x 8 MHz raster this module's callers run (448/7 MHz = 512/8 MHz), so the raster is unchanged and
- rtl/macross2/video_macross2.sv:355 Sprite generator: set_mask(0x3ff, 0x3ff) — 10-bit coordinates, wrap modulus 1024 (nmk16spr.cpp: `if (sx > max_x) sx -= xpos_max`), against 0x1ff/512 for the hi-res boards; max_sprite_clock 448*263.
- rtl/macross2/video_macross2.sv:514 Layer B's prefetch stream shares port B with the sprite fetch, real-time stream first: the sprite pass is a background compositing pass that simply runs slower while a two-layer game is drawing (its MAME budget is 25 % smaller on the lowres
- rtl/macross2/video_macross2.sv:591 Sprite ROM byte order on the hardware path: the ROMs are ROM_LOAD16_WORD_SWAP, and MAME's graphics decoder reads the region BYTE-wise from the swapped memory image, where byte b is raw file byte b^1 (the sim's $readmemh array is built that
- rtl/macross2/video_macross2.sv:681 Palette decode: RRRRGGGGBBBBRGBx (emupal.cpp RRRRGGGGBBBBRGBx_decoder)
- rtl/macross2/video_macross2.sv:761 cfg_rt: the full 14-bit (bank[1:0], code[11:0]) masked to the ROM's tile count (MAME: code % elements, a power of two for every board but the sprites' — see spr_units); the parameter form is the same for the two masks it can express.
- rtl/macross2/video_macross2.sv:782 one 256-colour bank: tilelayout_8bpp's planes 0-3 (the FIRST half, layer A) are MAME's pixel bits 7-4, planes 4-7 (the second half, layer B) bits 3-0
- rtl/macross2/video_macross2.sv:826 Found by comparing real-hardware captures against MAME snapshots, see docs/hw-bringup.md.
- rtl/macross2/video_macross2.sv:897 MAME copies the table atomically at the trigger (`sprite_dma()` from the scanline timer), as real hardware does.
- rtl/macross2/video_macross2.sv:1103 powerins mode only (get_flip_extcode_powerins, attr bit 12): the unit's SOURCE columns are mirrored (nmk16spr.cpp draws each tile with flipx through gfx->transpen) and the units are placed right to left (sx += delta*w, xinc negated) while t
- rtl/macross2/video_macross2.sv:1119 Tile code wraps modulo the ROM's element count (MAME: gfx_element does code %= total_elements).
- rtl/macross2/video_macross2.sv:1123 hachamf draws its big character sprite (the one over GAME OVER, and on the name-entry screen) with code 0x81D6 = 33238 against spr_units = 8192: MAME gives tile 33238 % 8192 = 470, the old chain gave 33238 - 2*8192 = 16854, which is not jus
- rtl/macross2/video_macross2.sv:1176 NMK214 descramble (NMK214=1) — per-fetch, exactly what MAME's decode_nmk214() precomputes: BG byte at byte address A becomes decode_byte(A, rom[A]); the big-endian sprite word at word address W becomes decode_word(W, word).
- rtl/macross2/video_macross2.sv:1181 Address bitswap tables: nmk16.cpp nmk214_bg_address_bitswap / nmk214_sprites_address_bitswap.
- rtl/macross2/video_macross2.sv:1444 Tiles that lie wholly outside the screen are skipped on their first pixel (MAME clips them too); the game keeps plenty of off-screen objects in its table, and walking their 256 pixels each (and fetching their ROM data) was a large part of w
- rtl/macross2/video_macross2.sv:1522 Reference (nmk16_v.cpp screen_update_macross draws m_spriteram_old2, sprite_dma() shifts old2 <- old <- mainram at line 242, the frame is rendered at VBOUT 240 before that DMA): frame j shows the table from DMA j-2.
- rtl/macross2/video_macross2.sv:1525 Pure RTL measurement — no MAME frame-index alignment involved.
- rtl/nmk112/nmk112.sv:6 Register interface: 8 write-only bank-select registers, addressed offset 0-7 (`okibank_w(offset,data)`, nmk112.cpp:86-98).
- rtl/nmk112/nmk112.sv:12 Address remap: PURE address-range decode, no awareness of which of jt6295's own 4 internal ADPCM channels issued a given fetch — confirmed directly from nmk112.cpp's own `oki_map()`/`oki_bank` (nmk112.cpp: 105-130): each OKI's own logical 0
- rtl/nmk112/nmk112.sv:23 Confirmed by reading jt6295's own internal channel round-robin (`rtl/third_party/jt6295/ hdl/jt6295_serial.v`'s own `ch` register) — it is NOT exposed on jt6295's own top-level port list, and (per the address-only nature of nmk112.cpp's own
- rtl/nmk112/nmk112.sv:31 Paged mode ("sample address table" independent per-voice banking, nmk112.cpp:6-9's own header comment): `is_paged(chip) = BIT(m_page_mask,chip)`, and the device's own default constructor value is `m_page_mask(0xff)` — since none of this pro
- rtl/nmk112/nmk112.sv:36 In paged mode, the FIRST 0x400 bytes of the chip's own ENTIRE logical address space (not per-window — confirmed: `map(0x00000,0x000ff)`..`map(0x00300,0x003ff)` are absolute, not offset by any bank window) are overlaid: sub-range N*0x100..N*
- rtl/nmk112/nmk112.sv:79 The core drives `hold` = "a gated cen is passing this clock"; the write is captured and applied on the next clock, after the latch — a 25 ns shift, far inside MAME's own sub-sample write/fetch ordering.
- rtl/nmk112/nmk112.sv:109 nmk112.cpp:93/96 mask every written page index with `data & m_bankmask[chip]` before storing it (m_bankmask is size-1 for a power-of-two page count, which every real OKI ROM in this hardware family is — 0x80000/0x100000/0x200000/0x400000 al
- rtl/nmk214/nmk214.sv:9 The descramble itself is address-dependent: which bitswap gets applied to a given word/byte depends on 3 bits pulled out of the *address* (after first re-ordering the address through ADDR_BITSWAP, since the 13 NMK214 address pins are wired
- rtl/nmk214/nmk214.sv:30 Width of the raw ROM address this instance's own ADDR_BITSWAP entries index into — NOT 13 bits: the reference's own per-game bitswap tables (nmk16.cpp's nmk214_sprites_address_bitswap/ nmk214_bg_address_bitswap) pick individual bits out of
- rtl/nmk214/nmk214.sv:72 Hardwired tables — verbatim from nmk214.cpp's own anonymous namespace.
- rtl/nmk_irq/nmk_irq.sv:10 MAME's own nmk_irq_device does NOT consume the H-timing PROM at all (commented out in nmk_irq.h/.cpp, and that file's own "TODO: Horizontal timing generator emulation?") — screen geometry instead comes from the fixed per-resolution-class pi
- rtl/nmk_irq/nmk_irq.sv:18 Every game using this hardware calls set_interrupt_timing() in nmk16.cpp unconditionally with the SAME fixed configuration (prom_start_offset=0x75, vtiming_prom_usage=0x100) — only the V-PROM's own 256-byte contents vary per game — so those
- rtl/nmk_irq/nmk_irq.sv:29 Verified via a live MAME debugger capture (breakpoints at mustang's own IRQ1-4 ISR entry addresses, resolved from the ROM's own autovector table, printing the debugger's `beamy` pseudo-symbol) against mustang's real, dumped V-PROM (`10.bpr`
- rtl/rom_cache_n.sv:7 Why (docs/hw-bringup.md, "Slowdown"): the real board and MAME run the 68000 with zero wait states from EPROM.
- rtl/rom_cache_n.sv:8 Through the 1-line rom_cache1 56% of ROM bus cycles missed (the instruction stream and the game's ROM data-table reads thrash a single pair) and each miss is a ~10 clk_sys SDRAM round trip, 1-2 wait states — 13-20% of every frame spent stal
- rtl/savestate/savestate_ui.sv:4 Slot 2 is on F5 and NOT F2 because every top level here already uses F2 for the Service Mode toggle (MAME's binding), and both were acting on the same press -- found on the board in the sibling Sand Scorpion core, 2026-09-20, which shares t
- rtl/seibu/seibu_sound.sv:7 Owns: the Z80-side register block at 0x4000-0x401B (seibu_sound_map, seibusound.cpp:333-350), the IM0 interrupt-vector arbitration between the YM3812 (RST10) and the 68000 (RST18) (update_irq_lines/im0_vector_cb, seibusound.cpp:137-204), an
- rtl/seibu/seibu_sound.sv:20 - YM3812's own register/data ports and audio synthesis (jtopl2) — this module only arbitrates cs/we/addr_sel and passes data through, exactly matching ym_r/ym_w's own pure pass-through implementation (seibusound.cpp:230-238).
- rtl/seibu/seibu_sound.sv:25 Main-CPU-side interface: mustangb (unlike the "full" Seibu games this device was originally written for) only ever exercises `main_mustb_w` — a single word write at 0x08001E/0x08001F on the 68000 side (main_mustb_w, seibusound.cpp:319-329)
- rtl/seibu/seibu_sound.sv:29 Confirmed directly against `mustangb_map` (nmk16.cpp:682-698): there is no read of main_r/soundlatch/pending anywhere in that map, so this module does NOT implement `main_r`'s own offset switch (the 68000-side readback of sub2main0/1/main2s
- rtl/seibu/seibu_sound.sv:43 RST18 takes priority when both are pending (im0_vector_cb, seibusound.cpp:184-204) — replicated exactly via the same VECTOR_INIT/RST10_*/RST18_* state machine the reference uses (update_irq_lines, seibusound.cpp:137-181), so a simultaneous
- rtl/seibu/seibu_sound.sv:94 ROM bank select (bank_w — BIT(data,0), seibusound.cpp:242-243)
- rtl/seibu/seibu_sound.sv:108 IRQ arbitration state — mirrors m_rst10_irq/m_rst10_service/ m_rst18_irq/m_rst18_service exactly (seibusound.cpp update_irq_lines, state names kept for direct traceability against the reference).
- rtl/seibu/seibu_sound.sv:120 RST18 wins over RST10 when both pending (im0_vector_cb, seibusound.cpp:186-197).
- rtl/seibu/seibu_sound.sv:148 main2sub / sub2main latches (soundlatch_r offset 0/1, main_data_w offset 0/1 — seibusound.cpp:257-270,295-329)
- rtl/seibu/seibu_sound.sv:155 One-cycle-delayed edge detect for the IACK acknowledge state updates below — matches the reference's own synchronize()-deferred (but same-effective-cycle, since MAME's scheduler.synchronize with no delay runs "now") state transitions: RST10
- rtl/seibu/seibu_sound.sv:182 RST10 (YM3812) assert/clear tracks the chip's own irq_n level directly (fm_irqhandler, seibusound.cpp:225-228).
- rtl/seibu/seibu_sound.sv:186 RST18 assert: main_mustb_w always asserts, unconditionally (seibusound.cpp:328).
- rtl/seibu/seibu_sound.sv:194 IACK: acknowledge the vector actually driven this cycle (RST10_ACKNOWLEDGE / RST18_ACKNOWLEDGE — note RST18's own acknowledge ALSO clears rst18_irq immediately, matching seibusound.cpp:171-174 exactly; RST10's ack only raises rst10_service,
- rtl/seibu/seibu_sound.sv:227 Z80-side register reads (main_r-equivalent offsets folded in: soundlatch_r=0x4010/11, main_data_pending_r=0x4012, coin_r=0x4013 hardwired 0xFF per mustangb's own machine config (coin_io_callback().set_constant(0xff), nmk16.cpp:4668))
- rtl/seibu/seibu_sound.sv:236 main_data_pending_r reads m_sub2main_pending, not m_main2sub_pending (seibusound.cpp:262-265)
- rtl/seibu/seibu_sound.sv:245 YM3812 pass-through (ym_r/ym_w, seibusound.cpp:230-238)
- rtl/tlcs90/nmk004_core.sv:90 debug: live register state + a direct peek at internal RAM[dbg_hl] — purely additive, for root-causing oracle divergences against MAME's own debugger register/memory readout (see docs/tier2-system.md, "RET Z at 0x0E5F").
- rtl/tlcs90/nmk004_periph.sv:25 - Timers 0-3 (8-bit, or 16-bit paired per TMOD) and timer 4/5 (16-bit compare-match with independent TREG4/TREG5 match points) are REAL counters, matching t90_timer_callback/t90_timer4_callback exactly — this is the one part of the peripher
- rtl/tlcs90/nmk004_periph.sv:64 This peripheral register map (`tmp90840_regs` in the reference's own `cpu/tlcs90/tlcs90.cpp`) is identical between the TMP90840 (NMK004's own role) and TMP91640 (the protection-MCU role) — confirmed directly, not assumed — so one module ser
- rtl/tlcs90/nmk_prot_core.sv:1 NMK-110/113/215 TLCS-90 shared-RAM protection MCU board wrapper — Tier 2's own Family D (`tdragon_prot_state` in the reference, mame/src/mame/nmk/nmk16.cpp:4895-5123 and nmk16.h:281-308).
- rtl/tlcs90/nmk_prot_core.sv:13 Confirmed directly from `mame/src/devices/cpu/tlcs90/ tlcs90.cpp`: `tmp91640_mem` (this role's own device, "TMP91640"/ "NMK-110"/"NMK-113") uses the *exact same* `tmp90840_regs` on-chip peripheral register map (0xffc0-0xffef) as `tmp90840_m
- rtl/tlcs90/nmk_prot_core.sv:24 Memory map (see tdragon_prot_map/tdragon_prot() in nmk16.cpp): 0x0000-0x3fff internal boot ROM (16KB — the actual protection program; per-game, e.g. nmk-110-tdragon.bin) 0xfdc0-0xffbf internal RAM (512B) 0xffc0-0xffef on-chip peripherals
- rtl/tlcs90/nmk_prot_core.sv:45 Port 5/6 protection-signalling (confirmed directly against `tdragon_prot_state::mcu_port5_r`/`mcu_port6_r`/`mcu_port6_w` in nmk16.cpp, not assumed from a generic port-latch model): - **Port 5 read** returns the current scanline position (`s
- rtl/tlcs90/nmk_prot_core.sv:87 `config.set_maximum_quantum(attotime::from_hz(6000))` in the reference (a scheduler-quantum tightening MAME itself needs for this specific timing-sensitive interaction) has no RTL analog: this design's own single shared `clk_sys` domain alr
- rtl/tlcs90/nmk_prot_core.sv:165 debug: live HL/A, for root-causing shared-RAM-content divergences against MAME's own debugger register readout (same technique nmk004_core.sv's own dbg_a/dbg_f/dbg_hl already use).
- rtl/tlcs90/tlcs90.sv:188 debug: pulses dbg_valid for one cycle at the start of each new instruction with that instruction's own PC — the same point in time MAME's `trace` debugger command reports from, directly diffable against a captured disassembly oracle trace.
- rtl/tlcs90/tlcs90.sv:196 debug: live register state, sampled alongside dbg_pc/dbg_valid — purely additive, for root-causing oracle divergences against MAME's own debugger register readout (A/HL/F match MAME's TLCS-90 debug state symbols of the same name).
- rtl/tlcs90/tlcs90.sv:420 Same OP_MUL/OP_DIV the PFX_G8 register-operand form already uses (reference: tlcs90.cpp:367-370, "case 0x12: case 0x13: OP(MUL+b0-0x12,16) R16(1,HL) I8(2,READ8())") — missing here entirely, same silent-OP_NOP-fallthrough class as the ADD ix
- rtl/tlcs90/tlcs90.sv:432 Confirmed directly against the reference (cpu/tlcs90/tlcs90.cpp:372-373, "case 0x14: case 0x15: case 0x16: OP16(ADD,6) R16(1,IX+b0-0x14) I16(2,READ16())") — this specific base (unprefixed) form was missing from this table entirely (the cycl
- rtl/tlcs90/tlcs90.sv:485 LDW ($FF00+w),mn — reuses OP_LD (MAME's own execute() merges "case LDW:" and "case LD|OP_16:" into the identical Write1_16(Read2_16()) path, tlcs90.cpp:1497-1499, so no new opcode is needed).
- rtl/tlcs90/tlcs90.sv:489 Missing here entirely (reference: tlcs90.cpp:419-420) — same silent-fallthrough class as above.
- rtl/tlcs90/tlcs90.sv:591 Table extracted directly from mame/src/devices/cpu/tlcs90/tlcs90.cpp's own OP()/OPCC()/OP16()/OPCC16() macro table (CT*2 = real clock cycles; conditional entries use the branch-taken result via the same test_cc() the EXECUTE stage itself us
- rtl/tlcs90/tlcs90.sv:597 DJNZ's own not-taken cost (0x18/0x19 below) is a deliberate exception to "look it up in this table": the reference's own `OP(DJNZ,10)` (tlcs90.cpp:379/381) only ever sets `m_cyc_t` — `m_cyc_f` (the not-taken cost `Cyc_f()` charges when the
- rtl/tlcs90/tlcs90.sv:873 XCF ("extra carry", bit 3) on INC/INCX/DEC/DECX: the reference (tlcs90.cpp's INC/INCX/DEC/DECX cases) computes F from the SZHV table alone (which never touches XCF) and then, as a genuinely separate step, sets XCF if-and-only-if the 8-bit r
- rtl/tlcs90/tlcs90.sv:878 This core's own szhv_inc8()/szhv_dec8() never included that bit, so every one of their 4 callers (OP_INC/OP_DEC's 8-bit forms, OP_INCX/OP_DECX) was silently clearing XCF to 0 unconditionally instead — found via a register-state trace diff a
- rtl/tlcs90/tlcs90.sv:1890 Two bugs lived here in turn: (1) SET/ RES always wrote to eff2/dout regardless of mode2, discarding the register form's result entirely (found via a register-state trace diff against a MAME oracle, docs/hw-bringup.md's GunNail investigation
- README.md:23 Sets MAME flags `MACHINE_NOT_WORKING` are out of scope until MAME can run them.
- README.md:26 Verify against MAME as the golden reference before hardware bring-up: MAME Lua tracers dump bus cycles, frames and RAM state, and Verilator testbenches diff the
- README.md:28 Hardware is then compared to MAME with HDMI screenshots and audio captures.
- README.md:31 MAME is used as a behavioural reference only.
- README.md:31 No MAME code is part of the built core.
- README.md:72 | Core (`releases/*.rbf`) | Hardware | Games (MAME set names) |
- README.md:74 | `NMK16_Macross2` | 68000 + Z80 sound, YM2203, 2x OKIM6295 with NMK112 banking; hi-res and Power Instinct's 320-px board as runtime modes, plus the bootleg boa
- README.md:76 | `NMK16_Gunnail` | NMK004 sound MCU, YM2203, 2x OKIM6295; NMK-215/113/110 protection MCUs with dual NMK214; hi-res per-line scroll (GunNail), the nine lowres N
- README.md:81 Audio is compared band by band against MAME captures.
- README.md:91 The four that do not ship are all `MACHINE_NOT_WORKING` in MAME itself, for reasons MAME states on its own `GAME` lines, and are outside this project's goal unt
- README.md:96 | Set | MAME's reason | Here |
- README.md:99 | `macrossbl` | *"not looked at yet"* | Not attempted — MAME has not characterised this bootleg at all, so there is nothing to port against. |
- README.md:126 Player inputs follow MAME's default key layout.
- README.md:226 The simulations read ROM images built from the MAME zips with the scripts in `tools/`.
- README.md:246 | `sim/oracle/`, `sim/compare/` | MAME Lua tracer and trace comparison |
- README.md:287 jt6805 is a **microcoded** design, and the control store is not jotego's. `rtl/m68705/6805.uc` (4096 x 39 bits) and the `6805.vh` / `6805_param.vh` headers that
- README.md:315 The behavioural reference is [MAME](https://github.com/mamedev/mame), in particular `src/mame/nmk/nmk16.cpp`, `nmk16_v.cpp`, `nmk16spr.cpp`, `nmk214.cpp`, `nmk0
- README.md:324 The project structure and the simulate-against-MAME methodology follow [kaneko16-mister](https://github.com/alphanu1/kaneko16-mister) and the MiSTer-devel arcad
- README.md:339 The MAME source tree and the arcade ROM images are not part of this repository and are not covered by this licence.
Says it matches, follows or was checked against MAME — 14
- rtl/bjtwin/nmk_irq_hacky.sv:18 IRQ levels are held (matching MAME's HOLD_LINE semantics for M68K, which auto-clears when the CPU takes the interrupt) until the CPU performs an interrupt-acknowledge bus cycle at that level.
- rtl/bjtwin/video_timing.sv:22 This was NOT assumed or guessed: every prior port's own polling loops tolerated the old vcount=0 reset silently (it only ever showed up as an already- documented, bounded residual cycle-cost mismatch in verification), and this project spent
- rtl/bjtwin/video_timing.sv:64 see header — matches MAME's own reset-time raster phase
- rtl/gunnail/gunnail_core.sv:2886 Widths now sum to exactly 16 and the layout matches tharrier's IN1 as MAME returns it (~IN1): bit0 START1, bit1 START2, bit5 COIN2, bit7 COIN1, bit8 START2.
- rtl/gunnail/gunnail_core.sv:2903 Unlike tharrier's own undumped/simulated MCU above, this bootleg's chip is fully dumped, so the game runs against the real thing: rtl/m68705/m68705_core.sv (jotego's jt6805 plus this project's peripheral wrapper), verified instruction-for-i
- rtl/gunnail/gunnail_core.sv:3616 Matched to MAME for this map only, to keep the blast radius off every other game on the rbf.
- rtl/gunnail/gunnail_core.sv:3727 afega_state::video_update instead reads the DIP bus LIVE every frame, as two independent axes: flip_screen_x_set(BIT(~m_dsw_io[0]->read(), 8)); // horizontal flip_screen_y_set(BIT(~m_dsw_io[0]->read(), 9)); // vertical (active low, and
- rtl/macross2/video_macross2.sv:340 Before this conversion the whole picture sat 28 pixels right and 16 lines down of MAME's (measured: shifting a sim frame by (-28,-16) matched MAME's snapshot on 96.5% of all pixels), pushing the rightmost 28 columns and bottom 16 rows off-s
- rtl/macross2/video_macross2.sv:1361 Latching in the same cycle as the address change (as this once did) delivered every word one offset late — the visible flag from the previous slot's colour word, the size from the flag word, the code from the size word — which is why moving
- rtl/nmk_irq/nmk_irq.sv:24 Phase calibration (empirically verified, not derived from documentation alone): MAME's own screen.vpos() — the `y` the reference's address formula uses directly — is NOT the same numbering as this project's own video_timing.sv `vcount` (bot
- rtl/tlcs90/nmk004_periph.sv:3 Built and verified against MAME's cpu/tlcs90/tlcs90.cpp reference model — see docs/tier2-tlcs90.md's "Peripheral registers" section for the full register map and which registers are confirmed exercised by the NMK004 boot ROM.
- rtl/tlcs90/tlcs90.sv:4 Built and verified against MAME's `cpu/tlcs90/tlcs90.cpp` reference model — see docs/tier2-tlcs90.md for the full ISA reference, memory map, and verification plan this was derived from (register model, addressing-mode encodings, exact per-o
- rtl/tlcs90/tlcs90.sv:1095 LDW (mem),mn — reuses OP_LD same as the base-level 0x3f form above (MAME merges LDW into LD|OP_16's own execute case).
- README.md:79 Each core is pixel-identical to MAME in simulation for the whole attract sequence that timing allows, and pixel-identical in hardware screenshots of static scen
Says it was translated, ported or taken from MAME — 4
- rtl/nmk112/nmk112.sv:2 Ported directly from mame/src/devices/machine/nmk112.cpp (131 lines, read in full before implementing — every detail below is confirmed against that source, not assumed).
- rtl/nmk214/nmk214.sv:1 NMK214 GFX descrambler — a stateless, table-driven dynamic bitswap of graphics-ROM data, ported directly from mame/src/mame/nmk/nmk214.cpp (device comment there has the hardware background: works in tandem with the NMK215/TMP90840 protectio
- rtl/nmk_irq/nmk_irq.sv:5 Ported directly from mame/src/mame/nmk/nmk_irq.cpp's own scanline_callback() — see that file's extensive header comment for the hardware background (dual counters + H/V timing PROMs inside the NMK902 custom chip).
- rtl/seibu/seibu_sound.sv:3 Ported directly from `seibu_sound_device` (mame/src/mame/shared/ seibusound.{h,cpp}), the Z80 sound-board peripheral used by mustangb/tdragonb/acrobatmbl/strahljbl (Tier 5, Family E — "Raiden sound" bootlegs of NMK16-family games that other
Keeps a MAME approximation — 3
- rtl/bjtwin/nmk_irq_hacky.sv:1 nmk_irq "hacky" fixed-scanline interrupt generator — the variant `cactus` uses (undumped timing PROMs on this bootleg; MAME substitutes a fixed scanline table, nmk16.cpp set_hacky_interrupt_timing()/nmk16_hacky_scanline, nmk16.cpp:4482-4511
- rtl/gunnail/gunnail_core.sv:21 - The nine others: set_screen_lowres (384 x 278 at 6 MHz, visible 92..347 — the same 64 us line as the 512 x 8 MHz raster, so this core keeps its raster and draws a 256-px window at hcount 92..347), 32x32 TX tilemap, frame-constant scroll r
- rtl/gunnail/gunnail_core.sv:3623 Raster timing + interrupt generation: the V-PROM state machine (three PROM tables, vprom_sel) or MAME's fixed-scanline substitute for strahl (irq_hacky).
Shares text with the MAME driver without saying so — 26
- NMK16_Gunnail.sv:414 acrobatmbl reads its DSW1 word with SW1 in the HIGH byte ("changed from move.w to move.b"), DSW2 as acrobatm — shares text with nmk/nmk16.cpp:2222
- rtl/gunnail/gunnail_core.sv:517 nmk16.cpp calls it "Like Thunder Dragon Bootleg without the Program Rom — shares text with nmk/nmk16.cpp:6129
- rtl/gunnail/gunnail_core.sv:896 afega_unknown_r: 0x0100 ("fixes the text in Service Mode") — shares text with nmk/nmk16.cpp:6313
- rtl/gunnail/gunnail_core.sv:2036 word 0x9F00 ("the protection device probably copies this to the — shares text with nmk/nmk16_v.cpp:432
- rtl/gunnail/gunnail_core.sv:2189 ("otherwise bioship doesn't hit the NMI enough"). — shares text with nmk/nmk16.cpp:237
- rtl/gunnail/gunnail_core.sv:2894 an active-low IPT_UNKNOWN ("VBLANK ? Check code at 0x005640") that — shares text with nmk/nmk16.cpp:1441
- rtl/gunnail/gunnail_core.sv:3005 0x060000-0x060021 read 0x00EE ("no sprites in attract mode without — shares text with nmk/nmk16.cpp:893
- rtl/gunnail/gunnail_core.sv:3729 flip_screen_x_set(BIT(~m_dsw_io[0]->read(), 8)); // horizontal — shares text with nmk/nmk16_v.cpp:519
- rtl/gunnail/gunnail_core.sv:3730 flip_screen_y_set(BIT(~m_dsw_io[0]->read(), 9)); // vertical — shares text with nmk/nmk16_v.cpp:520
- rtl/macross2/video_macross2.sv:3 `VIDEO_START_MEMBER(nmk16_state,macross2)` (nmk16_v.cpp:150-162) creates — shares text with nmk/nmk16_v.cpp:150
- rtl/macross2/video_macross2.sv:4 a `common_get_bg_tile_info<0,1>`-driven, `tilemap_scan_pages`-mapped, — shares text with nmk/nmk16_v.cpp:123
- rtl/macross2/video_macross2.sv:331 set_scrolldx(28+64,28+64) and the sprite generator's videoshift(28+64) — both in MAME BITMAP coordinates, see BITMAP_X0 below — shares text with nmk/nmk16_v.cpp:160
- rtl/macross2/video_macross2.sv:336 scrollx (hence MAME's own "leftmost 64 pixels have to be retrieved — shares text with nmk/nmk16_v.cpp:159
- rtl/macross2/video_macross2.sv:648 BG tile-fetch address — gfx_8x8x4_col_2x2_group_packed_msb layout: — shares text with nmk/nmk16.cpp:4184
- rtl/macross2/video_macross2.sv:737 tilemap_scan_pages: (row&0xf) | ((col&0xff)<<4) | ((row&0x10)<<8) — shares text with nmk/nmk16_v.cpp:36
- rtl/macross2/video_macross2.sv:752 common_get_bg_tile_info<0,1>: (code&0xfff)|(m_bgbank<<12) — 14-bit — shares text with nmk/nmk16_v.cpp:123
- rtl/macross2/video_macross2.sv:788 palette base and tile ROM; common_get_bg_tile_info<1, Gfx> — the — shares text with nmk/nmk16_v.cpp:107
- rtl/macross2/video_macross2.sv:829 TILEMAP_SCAN_COLS 8,8,32,32 — 256 logical px, the whole screen), so — shares text with nmk/nmk16_v.cpp:108
- rtl/macross2/video_macross2.sv:1182 nmk214_bg_address_bitswap / nmk214_sprites_address_bitswap. — shares text with nmk/nmk16.cpp:5700
- rtl/tlcs90/nmk004_periph.sv:59 reference (`tdragon_prot_state::mcu_port5_r`/`mcu_port6_r` — shares text with nmk/nmk16.cpp:5040
- rtl/tlcs90/nmk_prot_core.sv:34 `m_maincpu->space(AS_PROGRAM).read_byte(offset)`/`write_byte` — — shares text with nmk/nmk16.cpp:5100
- rtl/tlcs90/nmk_prot_core.sv:46 `tdragon_prot_state::mcu_port5_r`/`mcu_port6_r`/`mcu_port6_w` in — shares text with nmk/nmk16.cpp:5040
- rtl/tlcs90/nmk_prot_core.sv:61 "the actual mechanism is a little more complex, but these are — shares text with nmk/nmk16.cpp:5022
- rtl/tlcs90/nmk_prot_core.sv:62 written at the start and end of the take/release bus function"): — shares text with nmk/nmk16.cpp:5022
- rtl/tlcs90/nmk_prot_core.sv:87 `config.set_maximum_quantum(attotime::from_hz(6000))` in the — shares text with nmk/nmk16.cpp:5122
- rtl/tlcs90/nmk_prot_core.sv:371 only qualifying ones, matching `m_init_clock_nmk214 = BIT(data,2)` — shares text with nmk/nmk16.cpp:5669