← All cores
Arcade-HyperNG64 (ppriest)
Cites hardware documentation that MAME's driver does not — 1
- README.md:63 | Toshiba TMP87PH40AN (TLCS-870) | IO MCU: inputs, coins, lamps | microcoded from MAME's `tlcs870` (`rtl/io/`), runs the dumped ROM |
Notes where it differs from MAME — 1
- rtl/io/hng64_tlcs870.sv:341 ---- interrupts (check_interrupts, tlcs870.cpp:954) ---------------------------------------- Priorities 0..2 are non-maskable and MAME does not implement them; 3..15 need EIR bit 0.
Cites MAME source — 147
- HyperNG64.sv:163 MAME's default arcade keys, ORed into the pads
- HyperNG64.sv:238 MAME's coins are PORT_IMPULSE(1): one frame low per press.
- HyperNG64.sv:251 IN0-IN7, active low, as MAME's ports for the board (hng64.cpp hng64_fight, hng64_drive, hng64_shoot).
- HyperNG64.sv:254 drive: buttons 1-4 Accelerate, Brake, Shift Up, Shift Down (the pedals at full, digitally), 5-8 View 1, View 2, BGM 1, BGM 2; MAME has BGM 3 and 4 too, not mapped.
- HyperNG64.sv:292 drive: AN0 the wheel (MAME's paddle, 0x80 centred), AN1 accelerator, AN2 brake (0 at rest).
- HyperNG64.sv:295 shoot: AN0-AN5 the guns' X and Y, players 1-3: 0x80 centred and reversed, as MAME's AD_STICK ...
- HyperNG64.sv:343 a channel MAME's ports leave empty reads 0 there
- HyperNG64.sv:354 None of the fight sets has one in MAME; bit 0 of the first byte is the core's own Flip Screen, a fake DIP the game never reads.
- HyperNG64.sv:619 By default only register accesses (not main RAM, program ROM, BIOS, or the tilemap, sprite, palette, 3D-bank and sound memories the BIOS tests) and only the first 4,096 after configuration or a restart, which is the order MAME's system trac
- rtl/cpu/hng64_cpu.vhd:9 After SS_reset falls, Status is rewritten through the savestate port (COP0 slot 12 = SS_Adr 76) with the VR4300 cold-reset value BEV|ERL = 0x00400004, which is also MAME's (mips3.cpp:1115).
- rtl/cpu/hng64_cpu.vhd:11 Config (slot 16 = SS_Adr 80) is set the same way to MAME's 0x0000E460; the N64's 0x7006E460 has its clock-ratio field set (docs/MAME_KLUDGES.md).
- rtl/cpu/hng64_cpu.vhd:156 The CPU posts stores to a write FIFO and runs on; MAME applies a store before the next instruction.
- rtl/cpu/hng64_cpu.vhd:157 The games' interrupt handler acknowledges the controller (sw 0xBF70111C) three instructions before it sets IE, so with the store still queued the line is high at IE and a nested interrupt is taken that MAME never sees.
- rtl/cpu/vr4300/cpu_cop0.vhd:443 local: MAME reads 0 here; see PROVENANCE.md
- rtl/cpu/vr4300/cpu_cop0.vhd:1007 HyperNG64: an entry not valid for the page is passed over, as MAME's vtlb holds only valid pages; upstream stops at it and raises TLB invalid.
- rtl/hng64_3d.sv:7 MAME renders a display list the moment it is uploaded and raises interrupt 3 a fixed 5,120 CPU cycles later whatever the work (hng64_io.sv, D_DLUP).
- rtl/hng64_3d.sv:8 The engine takes longer than that for most uploads, so each upload copies the display list (256 u16) and the texture-wrap bytes into a slot of a queue, and the engine takes the slots in order; the game keeps MAME's timing while the engine c
- rtl/hng64_3d.sv:12 A clearing vblank (tcram 0x50 bit 16, MAME's screen_vblank) is queued as an event of its own between the uploads either side of it.
- rtl/hng64_3d.sv:53 MAME's screen vblank (hng64_vtiming vblank_level)
- rtl/hng64_bus.sv:3 HNG64 main bus: the N64 core's VR4300 memory port (rtl/cpu/vr4300/cpu.vhd) to - a 64-bit backing store for RAM, program ROM and BIOS (mem_*), which also feeds cache fills on the clk2x beat bus, and - a 32-bit I/O port (io_*) for everything
- rtl/hng64_bus.sv:62 Plain memory in MAME's map, kept in SDRAM or DDR3 by hng64_mainmem, which has the same table.
- rtl/hng64_bus.sv:137 A 64-bit access (the games read the IO MCU's dual-port RAM with ld) is two word accesses, +0 then +4, as MAME's 32-bit handlers see it; this is the +0.
- rtl/hng64_core.sv:54 IN0-IN7, active low, as MAME's ports for the board
- rtl/hng64_io.sv:3 The main CPU's I/O space: everything in MAME's main_map (hng64.cpp:1182) that is a device rather than plain memory.
- rtl/hng64_io.sv:20 0x20300000 3D display list written through to hng64_3d's copy; an upload queues it there and raises interrupt 3 a fixed time later as MAME's does 0x30000000 3D buffer control stored; 0x08 the buffer's x scroll 0x60000000 sound RAM
- rtl/hng64_io.sv:30 Times MAME gives in main-CPU cycles are its 50 MHz clock (hng64.h:218); they are counted here in clk1x cycles at 62.5 MHz, which is 5/4 as many and exact for every value used.
- rtl/hng64_io.sv:36 m_no_machine_error_code, the board's: 1 fight, 2 drive, 3 shoot (hng64.cpp init_*), from the .mra
- rtl/hng64_io.sv:47 the CPU's interrupt input (MAME's input line 0)
- rtl/hng64_io.sv:68 the host's port on the NVRAM (the .nvm file, ioctl index 4), in bytes in MAME's file order: its share is a u32 array saved little-endian, so byte j is bits 8(j%4)+7:8(j%4) of dword j/4 as the CPU sees it.
- rtl/hng64_io.sv:174 MAME's COMBINE_DATA with a big-endian mem_mask: be[3] is bits 31:24
- rtl/hng64_io.sv:246 ---- interrupt controller (set_irq, hng64.cpp:1871) -------------------------------------------------
- rtl/hng64_io.sv:273 MAME's loop stops at bit 30, so bit 31 alone asserts the line with a stale level
- rtl/hng64_io.sv:276 ---- RTC, MSM6242 (msm6242.cpp) --------------------------------------------------------------------
- rtl/hng64_io.sv:315 the block is 32 dwords; the odd ones carry registers 0-15 (rtc_r, hng64.cpp:788)
- rtl/hng64_io.sv:348 The sprite clears (sprite_clear_even_w / _odd_w, hng64.cpp:1075): each write clears four dwords of one sprite or of two, 0x40 bytes a pair.
- rtl/hng64_io.sv:425 MAME's machine_start (hng64.cpp:2179)
- rtl/hng64_io.sv:606 main_sound_comms (hng64.cpp:1137), 16 bits wide, with the stand-in for the missing sound CPU: status 0x0080, and the data latch holding the command before the last trigger (HARDWARE_NOTES "Sound mailbox")
- rtl/hng64_io.sv:634 soundcpu_enable_w (hng64_a.cpp): the upper half is the command; MAME maps no read
- rtl/hng64_io.sv:652 dualport_r / dualport_w (hng64.cpp:1017): one byte per enabled lane, addr+0 first.
- rtl/hng64_io.sv:704 the copy runs on clk2x; the write is not acknowledged until it is done, so the CPU sees it as atomic, as MAME's is
- rtl/hng64_keyboard.sv:3 MAME's default keys (src/emu/inpttype.ipp), in this core's J1 joystick layout so they OR into the pads: right, left, down, up at bits 0-3, buttons 1-4 at 4-7, Start 8, Coin 9, Pause 10, Service 11, Test 12.
- rtl/hng64_keyboard.sv:7 P1 arrows, LCtrl LAlt Space LShift, 1 start, 5 coin P2 R F D G, A S Q W, 2 start, 6 coin P pause, 9 service (MAME's Service 1), F2 test (MAME's Service Mode)
- rtl/hng64_sndbridge.sv:24 Once the sound CPU is enabled, its replies stand in the mailbox while its heartbeat moved in the last LIVE polls, whether or not it has started its V53A yet: until then its latches read 0, as MAME's V53A held in reset leaves them, and the g
- rtl/hng64_sndbridge.sv:172 MAME's soundcpu_enable_w: 0x55AA releases the V53A from reset, 0xAA55 holds it
- rtl/io/hng64_iomcu.sv:3 The IO board's MCU, with what MAME puts around it: the TMP87PH40AN's memory map and peripherals (src/devices/cpu/tlcs870/tlcs870.cpp) and the HNG64 board wiring on its ports (src/mame/snk/hng64.cpp:2285-2530).
- rtl/io/hng64_iomcu.sv:7 MEMORY MAP (tmp87ph40an_mem, tlcs870.cpp:24) 0x0000-0x003f SFRs.
- rtl/io/hng64_iomcu.sv:9 0x0040-0x023f internal RAM, which also holds the register banks 0x0f80-0x0fff DBR; 0x0ff0-0x0fff are the serial buffers 0xc000-0xffff ROM, the top 16 KB of the 32 KB dump Anything else reads 0, MAME's default for an unmapped read, and ig
- rtl/io/hng64_iomcu.sv:18 out: lamps and coin counters P7 out: bits 3:2 the dual-port RAM address's top two bits; a falling bit 0 clears the nine-bit counter under them, a falling bit 1 advances it, a falling bit 7 interrupts the MIPS Every other port reads 0xff fr
- rtl/io/hng64_iomcu.sv:24 PERIPHERALS, AS MAME HAS THEM - which is less than the chip has (docs/MAME_KLUDGES.md): timer 2 fires INTTC2 every 1,500 MCU cycles while TC2S is set, whatever TREG2 and the clock select say (`tc2_reload`, "TODO: use real value") serial
- rtl/io/hng64_iomcu.sv:181 status registers MAME reads as 0
- rtl/io/hng64_iomcu.sv:212 sio0_transmit_cb (tlcs870.cpp:577): one bit; after the eighth, the next byte, and after the last byte the interrupt.
- rtl/io/hng64_iomcu.sv:325 device_reset (tlcs870.cpp:1027)
- rtl/io/hng64_iomcu.sv:339 IL bits are 15 minus MAME's enum: INT0 is bit 3, INTSIO1 bit 9, INTTC2 bit 14.
- rtl/io/hng64_tlcs870.sv:9 MAME executes an instruction atomically and charges it a cycle count (`m_cycles`, one tick of the 8 MHz clock).
- rtl/io/hng64_tlcs870.sv:15 Instruction boundaries therefore land where MAME's do, which is what decides when an interrupt is taken.
- rtl/io/hng64_tlcs870.sv:29 `get_reg8` is `intram[(RBS & 0xf) * 8 + (reg & 7)]` (tlcs870_ops_helper.cpp:17) and intram is mapped at 0x0040, so register r of bank RBS is the byte at 0x0040 + RBS*8 + r and the program can reach it as ordinary RAM.
- rtl/io/hng64_tlcs870.sv:36 A read of an I/O port normally sees the pins, but MAME clears `m_read_input_port` in a set of read-modify-write handlers so that they see the port's output latch instead (tlcs870.cpp:140).
- rtl/io/hng64_tlcs870.sv:39 SET (pp).g and LD (pp).g,CF read the pins, as MAME's do.
- rtl/io/hng64_tlcs870.sv:79 MAME's m_addr: advances through the operand bytes
- rtl/io/hng64_tlcs870.sv:162 get_addr (tlcs870_ops_helper.cpp:118).
- rtl/io/hng64_tlcs870.sv:186 ---- condition codes (check_jump_condition, tlcs870_ops_helper.cpp:163) --------------------
- rtl/io/hng64_tlcs870.sv:343 MAME's loop runs upwards and returns on the first match, so the lowest index wins.
- rtl/io/hng64_tlcs870.sv:408 MAME's il_h_w takes the low byte from EIR, not IL (tlcs870.cpp:887); see docs/MAME_KLUDGES.md
- rtl/io/hng64_tlcs870.sv:448 take_interrupt (tlcs870.cpp:982).
- rtl/io/hng64_tlcs870.sv:448 MAME charges it no cycles.
- rtl/io/hng64_tlcs870.sv:507 A source or destination prefix whose mode is (x) or (HL+d) carries its address immediate BEFORE the second opcode byte (tlcs870_ops_dst.cpp:38), so that byte is taken first and the opcode read is issued behind it.
- rtl/io/hng64_tlcs870.sv:532 f1 and f5 are illegal for a destination, and MAME charges the extra cycle and then runs the opcode anyway (dst.cpp:49)
- rtl/io/hng64_tlcs870.sv:543 The effective address a source or destination prefix names, shared by both (get_addr, tlcs870_ops_helper.cpp:118).
- rtl/io/hng64_tlcs870.sv:720 MAME jumps to the vector's ADDRESS, not through it (tlcs870_ops.cpp:985)
- rtl/io/hng64_tlcs870.sv:736 handle_mul: only the flags are observable (the registers are written back unchanged, tlcs870_ops_helper.cpp:91); shift-and-add
- rtl/io/hng64_tlcs870.sv:747 handle_div (tlcs870_ops_helper.cpp:52): restoring, 16 steps; the quotient's low byte goes to the register this step names
- rtl/io/hng64_tlcs870_alu.sv:11 TWO PLACES FOLLOW MAME RATHER THAN THE MANUAL, and both are in docs/MAME_KLUDGES.md:
- rtl/io/hng64_tlcs870_alu.sv:13 set_CF() : clear_CF()` under a comment that says "JF is copied from CF" (tlcs870_ops_helper.cpp:280, 318, 355, 388).
- rtl/io/hng64_tlcs870_alu.sv:15 MAME instead overwrites the carry with zero-ness and never touches JF.
- rtl/io/hng64_tlcs870_alu.sv:49 The carry out is computed by MAME and then thrown away: see the header.
- rtl/io/hng64_tlcs870_alu.sv:75 MAME: CF from ZF, see the header
- rtl/io/hng64_tlcs870_alu.sv:82 MAME: CF from ZF, see the header
- rtl/memory/hng64_dma.sv:3 The main board's DMA (do_dma, hng64.cpp:811): dwords from one address to another, len + 1 of them.
- rtl/memory/hng64_dma.sv:4 MAME does the whole copy inside the CPU's write to the length register; here hng64_io.sv holds that write unacknowledged until the copy is done, so the CPU sees the same thing - nothing between the write and the copy being complete.
- rtl/memory/hng64_dma.sv:10 MAME's copy goes through the whole address space; this one reaches the backing store only, which covers the one copy the boot makes (1,024 dwords from `gameprg` + 0x200 to RAM 0x1000) and every copy of that kind.
- rtl/memory/hng64_mainmem.sv:9 0x04000000 32 MB `gameprg` DDR3, read only (MAME maps it `nopw`)
- rtl/memory/hng64_mainmem.sv:16 The last four are plain memory in MAME too (`videoram_w` only marks MAME's own tile cache dirty, and `soundram_w`'s word swap is undone by `soundram_r`), so they come through here rather than through the I/O port, which would put a second c
- rtl/memory/hng64_mainmem.sv:21 A write to `gameprg` or the BIOS is dropped, as MAME drops it.
- rtl/video/hng64_fb3d.sv:5 MAME's blit (hng64_v.cpp:868-923, render_3d.py blit_line) stretches the buffer's 512 lines over the game's visible ones: screen line y shows buffer row ((y - min_y) * yinc) >> 16, with yinc = (512 << 16) / (visible height - 1), and fbscroll
- rtl/video/hng64_mixer.sv:3 Line mixer: the four tilemap layers and the sprite layer to RGB, as MAME's screen_update does (hng64_v.cpp:743-940, transcribed in scripts/render_model.py).
- rtl/video/hng64_mixer.sv:6 MAME walks priority 0x1f down to 0x00; at each step the layers with that priority draw, and every fourth step one sprite group draws.
- rtl/video/hng64_mixer.sv:11 A pixel therefore has up to six contributors - four layer indices, one sprite value (whatever won the sprite z-buffer) and the 3D buffer's pixel, which MAME blits after step 0x10 (hng64_v.cpp:868).
- rtl/video/hng64_mixer.sv:13 They are ranked by the same key MAME's walk implies, then composited in that order.
- rtl/video/hng64_mixer.sv:22 The 3D pixel is `llll appp pppp pppp`: m_palette_3d (render_3d.py palette3d) is the modified palette entry p | fbcontrol[2] bit 5 << 11, plus l << 2 on each channel (saturating), through fade 0; a is MAME's fixed half-alpha.
- rtl/video/hng64_mixer.sv:26 THE MODIFIED PALETTE is built at each frame_start, as MAME builds its palette state at screen_update: every entry through the eight region modifiers, one modifier a clock with one unit, into a RAM the pixel path reads.
- rtl/video/hng64_mixer.sv:29 A palette or tcram write during the frame shows from the next frame, as in MAME (except at its video-register splits).
- rtl/video/hng64_mixer.sv:33 No multiplies or divides (WORKFLOW 14): every blend is a saturating add, or a halving add for alpha at MAME's fixed level of 0x80.
- rtl/video/hng64_mixer.sv:102 Mode 1 adds, 3 subtracts (hng64_v.cpp:1209).
- rtl/video/hng64_mixer.sv:122 alpha_blend_r32 at MAME's fixed level of 0x80 is (s + d) >> 1 per channel
- rtl/video/hng64_mixer.sv:140 ---- the six contributors of the words just read, and their rank --------------------------- Rank is MAME's walk: priority counts down, layers before the sprite group at the same step, layers among themselves in index order (hng64_v.cpp:838
- rtl/video/hng64_mixer.sv:148 {nothing to draw, MAME's order}
- rtl/video/hng64_mosaic.sv:3 Mosaic's first line of a group: x rounded down to a multiple of m + 1, which MAME writes as x - x % (m + 1) (hng64_v.cpp, hng64_sprite.ipp:349).
- rtl/video/hng64_sprite.sv:3 Sprite engine: the NEO64-SPR list as MAME draws it (hng64_sprite.ipp, transcribed in scripts/render_model.py draw_sprites), per line instead of per frame.
- rtl/video/hng64_sprite.sv:6 MAME walks the list once and draws each sprite's whole height into a screen-sized bitmap with a z-buffer.
- rtl/video/hng64_sprite.sv:9 Order within a line is list order, as MAME's is.
- rtl/video/hng64_sprite.sv:121 fields of the sprite the front end has MAME adds the offset and then sign-extends to 10 bits (hng64_sprite.ipp:284-289), so a position wraps at 1024: sams64's ranking title sits at 480 + 0xfe40, on screen at 32
- rtl/video/hng64_sprite.sv:259 Rows are 8 bytes apart; an 8bpp row's second half sits 128 bytes on (hng64.cpp:1729-1750).
- rtl/video/hng64_sprite.sv:384 4bpp: one 64-bit beat is the whole 16-pixel row, nibbles in MAME's order (hng64.cpp:1735).
- rtl/video/hng64_sprite.sv:579 destination height: step the source until it covers the chained tiles Not a candidate: zoom 0 and zsort's zval 0 (hng64_sprite.ipp:319-334), and without zsort zval 0x7ff, which no z-test passes (the buffer clears to 0x7ff, `<` after): fatfu
- rtl/video/hng64_sprite.sv:603 a chained sprite's tiles are the entries after it (hng64_sprite.ipp:303): the next sprite is (chainx + 1) * (chainy + 1) on
- rtl/video/hng64_sprite.sv:676 MAME tests zoom where it draws, not only in a list walk: a zoom of 0 here would never finish an x-flipped tile's width count (D_WIDTH)
- rtl/video/hng64_sprite.sv:689 mosaic keeps the first line of each group (hng64_sprite.ipp:349): found by hng64_mosaic in L_MOS, only when the sprite has mosaic
- rtl/video/hng64_sprite.sv:756 without chaining the tile number walks with the offset instead 8bpp halves the code BEFORE the chain offset is added (hng64_sprite.ipp:219-235), not after
- rtl/video/hng64_sprite.sv:852 dstwidth: destination pixels this tile covers (hng64_sprite.ipp:390)
- rtl/video/hng64_sprite.sv:863 x-flip starts at the tile's last source pixel and steps back (hng64_sprite.ipp:180): cursrcx = (dstwidth - 1) * dx, dx negated
- rtl/video/hng64_tilemap.sv:3 One tilemap layer, one line at a time: NEO64-SCC as MAME models it (hng64_v.cpp:49-685, transcribed in scripts/render_model.py).
- rtl/video/hng64_tilemap.sv:26 The tile ROM is the region AFTER MAME's init reorder (hng64.cpp:1814); the .mra applies the same reorder when loading, so the ROM here is what the decoder expects.
- rtl/video/hng64_tilemap.sv:41 videoregs[2]/[3] half (hng64_v.cpp:585)
- rtl/video/hng64_tilemap.sv:107 ---- the layer's scroll words, and the four steps they give ------------------------------- Three layouts (hng64_v.cpp:143-318): plain, per line, and the rotating "alt" one buriki's title screen uses.
- rtl/video/hng64_tilemap.sv:121 in line mode a line word is used only when its low byte is 0 (hng64_v.cpp:298)
- rtl/video/hng64_tilemap.sv:156 MAME's optimised loop: no rotation and no wrap, so the line starts at the first in-range pixel and stops at the first one past the map.
- rtl/video/hng64_tilemap.sv:179 each layer owns 0x4000 words of VRAM (hng64_v.cpp:49, tile_index + (Which << 14))
- rtl/video/hng64_tilemap.sv:240 A row is a 32-bit word every 4 bytes, but the layouts skip: rows 8-15 of a 16-tall tile start 8 rows further on (hng64.cpp yoffsets 0..7*32 then 16..23*32), and the pixels of one row are spread over up to four words at 0, 32, 128 and 160 by
- rtl/video/hng64_tilemap.sv:331 Bit offsets are MSB-first across the word, so offset k is word[31-k]: 4bpp xoffsets 24,28,8,12,16,20,0,4 (hng64.cpp:1678) and 8bpp 24,8,16,0.
- rtl/video/hng64_vbus.sv:17 MAME draws sprites at vblank from the list as it stands then (screen_update, hng64_v.cpp:745), and the CPU rewrites the list during the frame.
- rtl/video/hng64_vbus.sv:26 The background colour is palette entry 0 when bit 0 of the 3D buffer control's first byte is set, else black, as tb_video has it from MAME (hng64_v.cpp, screen_update).
- rtl/video/hng64_vbus.sv:52 The game's visible window and screen disable, as tcram_w keeps them (hng64_v.cpp:1389): taken on each write to tcram 0x08 from 0x04 (x0, y0) and 0x08 (width, height); a zero width or height disables the screen and leaves the window.
- rtl/video/hng64_vbus.sv:135 The engine's copy of the two it uses is taken with the sprite list, as MAME reads them at screen_update: the games write them several times a frame, and the bpp bit changing under a line left the engine's colour and row queues a tile apart,
- rtl/video/hng64_vbus.sv:164 MAME's machine_start fills them with 0xdeadbeef, register 0 apart (hng64.cpp:2174), and the BIOS read-modifies-writes them, keeping some of the fill (MAME_KLUDGES.md)
- rtl/video/hng64_video.sv:16 Reading a line ahead means a mid-screen write to tile VRAM or the registers takes effect one line later than MAME would show it.
- rtl/video/hng64_video.sv:131 The engines decode MAME's layouts from the other end, the lowest address in bits 63:56, so the granule is reversed here, once, for both tile ROMs - as the Psikyo core's gfxrom_byte_reorder.sv does for the same reason.
- rtl/video/hng64_video.sv:242 MAME's init_reorder_gfx (hng64.cpp:1814) interleaves the region's two halves in 32-byte units before decoding, and the engines address the decoded region.
- rtl/video/hng64_vtiming.sv:5 MAME's screen (hng64.h:218-229): a 25 MHz pixel clock, 768 x 528 total, 512 x 448 visible, 61.65 Hz.
- rtl/video/hng64_vtiming.sv:7 The board draws 264 lines a field, interlaced, which MAME runs as 528 progressive lines; this does the same.
- rtl/video/hng64_vtiming.sv:21 MAME has no flip for this board; the check is the unflipped frame rotated (sim/sys_tb).
- rtl/video/hng64_vtiming.sv:27 INTERRUPTS, as MAME's scanline timer raises them (hng64_irq, hng64.cpp:2128): it runs on every even line of the 528, as line/2 of 264.
- rtl/video/hng64_vtiming.sv:85 ours, MAME gives none: centred in the blanking, 96-pixel porches.
- rtl/video/hng64_vtiming.sv:258 MAME's scanline_shifted
- rtl/video/hng64_vtiming.sv:278 the screen's vblank() as MAME reports it: outside the window's lines
- README.md:3 A MiSTer FPGA core for SNK's Hyper NeoGeo 64 arcade hardware (MAME's `hng64`), built with Quartus Prime 17.0.2 Lite for the DE10-nano.
- README.md:45 | Name | Year | MAME set | On hardware |
- README.md:55 The drive sets' network board is not emulated: as MAME, the core answers its network check (`docs/MAME_KLUDGES.md`), so each runs as a single cabinet.
- README.md:63 | Toshiba TMP87PH40AN (TLCS-870) | IO MCU: inputs, coins, lamps | microcoded from MAME's `tlcs870` (`rtl/io/`), runs the dumped ROM |
- README.md:64 | main board I/O | interrupts, DMA, RTC, NVRAM, dual-port RAM | from MAME's driver (`rtl/hng64_io.sv`) |
- README.md:65 | NEO64-SCC, NEO64-SPR | four tilemaps, sprites, mixer | from MAME's video (`rtl/video/`) |
- README.md:67 | V53A + L7A1045 | sound CPU and DSP | MAME's code, run on the ARM (`sw/hng64snd`), linked to the core through DDR3 (`rtl/hng64_sndbridge.sv`); [Sound](#sound)
- README.md:91 Two players, an 8-way stick and four buttons each, as MAME's `hng64_fight` ports.
- README.md:126 They are MAME's code, taken out of MAME and built as `hng64snd`, a Linux program that runs on the DE10-nano's ARM beside Main_MiSTer (`sw/hng64snd/PROVENANCE.md
- README.md:196 MAME, and YouTube recordings of ports are the accuracy reference.
- README.md:200 Whole board less the CPU, replaying MAME's boot: frames 400 and 800 pixel-exact, also flipped (`sim/sys_tb`)
- README.md:233 | `debug` | reference captures from MAME used as ground truth (gitignored) |
- README.md:234 | `roms` | your own MAME sets (gitignored, never committed) |
Says it matches, follows or was checked against MAME — 5
- rtl/hng64_core.sv:420 ---- the IO MCU, on clk1x: 8 MHz from 62.5, as an accumulator (16/125 exactly) ------------------- 7.8 clocks a tick; sim/iomcu_tb matches MAME with no overrun at 5 (+cediv=5)
- rtl/io/hng64_tlcs870.sv:3 Transcribed from MAME's src/devices/cpu/tlcs870/, which is the accuracy reference: where MAME and the Toshiba manual disagree this follows MAME, and each place is in docs/MAME_KLUDGES.md.
- README.md:198 Main CPU: the BIOS's first 199,998 instructions match MAME in PC and all 31 registers (`sim/boot_tb`)
- README.md:199 IO MCU: 3,000,000 instructions match MAME's trace (`sim/iomcu_tb`); its decode agrees with MAME's dispatch on every opcode (`scripts/check_tlcs870_dispatch.py`)
- README.md:201 2D video: every captured layer, the sprites and the mixer pixel-exact to a model of MAME's renderer on captures of `sams64`, `fatfurwa` and `buriki` (`sim/tilem
Says it was translated, ported or taken from MAME — 3
- rtl/io/hng64_tlcs870.sv:3 Transcribed from MAME's src/devices/cpu/tlcs870/, which is the accuracy reference: where MAME and the Toshiba manual disagree this follows MAME, and each place is in docs/MAME_KLUDGES.md.
- rtl/io/hng64_tlcs870_alu.sv:3 TLCS-870 ALU and the single-operand transforms, transcribed from MAME's src/devices/cpu/tlcs870/tlcs870_ops_helper.cpp.
- README.md:179 `docs/ROADMAP.md` is the plan, `docs/HACKS.md` this core's approximations, `docs/MAME_KLUDGES.md` what is taken from MAME as is, and `docs/LESSONS_LEARNED.md` w
Keeps a MAME approximation — 8
- rtl/hng64_3d.sv:20 So the display shows the last finished frame, one behind MAME's, which shows the buffer as it is being drawn (docs/HACKS.md).
- rtl/hng64_io.sv:228 MAME's comhack (hng64.cpp comhack_callback): 400,000,000 of its 50 MHz CPU clocks after reset, 500,000,000 clk1x, the word at 0xc0001000 gets bit 0, the network id the drive sets' network check waits for, as the KL5C80 would answer (MAME_KL
- rtl/hng64_io.sv:230 It is MAME's |= on RAM: read ORed with com_hack, which a CPU write to that byte clears, so a later write stands.
- rtl/io/hng64_iomcu.sv:34 The MCU's own interrupt timing is therefore MAME's, not the chip's: see HACKS.md.
- rtl/video/hng64_video.sv:17 Real hardware fills a line buffer during the previous scanline too, so this is closer to the board than to MAME; it is in docs/HACKS.md either way.
- rtl/video/hng64_video.sv:77 roadedge: fbcontrol2 bit 5 leaves the 3D palette base (MAME's m_roadedge_3d_hack)
- rtl/video/hng64_vtiming.sv:6 MAME gives no sync positions; the ones here are ours (HACKS.md).
- README.md:70 Video: 25 MHz pixel clock, 512 x 448 visible of 768 x 528, 61.65 Hz, as MAME's screen; MAME gives no sync positions, so those are this core's (`docs/HACKS.md`).
Shares text with the MAME driver without saying so — 1