← コア一覧
Arcade-SegaYBoard (rossops)
MAMEのドライバにない実基板の資料を引用 — 2
- rtl/io/yb_msm6253.sv:5 Channel 3 comes through the 74HC4052 selected by port E bits 1:0, so MAME's seven analog ports are ch0-2 and mux0-3; the descriptor's reverse mask is per MAME channel like PORT_REVERSE (0x100 - value on a 1..FF range).
- rtl/yb_core.sv:303 The seven MAME channels are ADC 0-2 and the 74HC4052 inputs 0-3 on channel 3.
MAMEとの相違点を記載 — 2
- rtl/yb_core.sv:688 a write into ROM space is acknowledged and dropped: the board's DTACK logic does not look at R/W and MAME ignores it; G-LOC R360 clears 64 KB at 040000 on the way into a fight and stalled here until the watchdog
- README.md:179 `docs/DESIGN.md` records the results per milestone, and where the RTL deliberately differs from MAME.
MAMEのソースを引用 — 57
- rtl/audio/yb_segapcm_5218.sv:2 Sega 315-5218 PCM (SegaPCM), MAME segapcm.cpp.
- rtl/audio/yb_segapcm_5218.sv:11 The sums are in MAME's 1/32768 units, i.e. directly 16-bit samples.
- rtl/audio/yb_segapcm_5218.sv:13 ROM bytes come from SDRAM port p6 (16-bit words, byte selected by A0); the stream pads the PCM slot with 0xFF like MAME's ERASEFF region.
- rtl/audio/yb_segapcm_5218.sv:20 MAME m_bankshift (Y Board 13, X Board 12)
- rtl/audio/yb_segapcm_5218.sv:45 MAME m_low: addr[7:0] per channel
- rtl/audio/yb_soundsys.sv:8 Mix: MAME routes the Y Board's PCM at 0.70 and its YM2151 at 0.30 of full scale (the X Board's were 0.35 and 0.15); the gains are parameters in 1/256.
- rtl/cpu/yb_math_5248.sv:4 Reference: MAME segaic16_m.cpp.
- rtl/cpu/yb_math_5249.sv:10 Reference: MAME segaic16_m.cpp sega_315_5249_divider_device::execute.
- rtl/cpu/yb_math_5249.sv:74 operands as they are after this same write (MAME updates the register first, then executes)
- rtl/cpu/yb_math_5249.sv:151 MAME: remainder = dividend - clamped_q * divisor
- rtl/io/yb_315_5296.sv:5 Reading an output port returns its latch, an input port the pin; a write always lands in the latch and drives the pin only while the port is an output (MAME refreshes an input port's callback with 0).
- rtl/io/yb_315_5296.sv:9 CNT0-2 and CKOT are not modelled (MAME leaves them too).
- rtl/io/yb_315_5296.sv:9 Reference MAME 315_5296.cpp; verif/models/io5296.py is the golden model.
- rtl/io/yb_msm6253.sv:5 Channel 3 comes through the 74HC4052 selected by port E bits 1:0, so MAME's seven analog ports are ch0-2 and mux0-3; the descriptor's reverse mask is per MAME channel like PORT_REVERSE (0x100 - value on a 1..FF range).
- rtl/io/yb_msm6253.sv:8 Conversion is instant, as in MAME (the real chip's CKOT-clocked conversion time is open question 8).
- rtl/io/yb_msm6253.sv:10 Reference MAME msm6253.cpp; verif/models/msm6253.py is the golden model.
- rtl/io/yb_msm6253.sv:21 descriptor bit n: MAME channel n reads 255 - value
- rtl/io/yb_msm6253.sv:31 PORT_REVERSE on MAME's 0x01..0xFF ranges is (max + min) - value = 0x100 - value, so a centred stick stays 0x80; the core's axes reach 0, which maps to 0xFF
- rtl/mem/yb_fb_if.sv:5 Empty framebuffer pixel = 0xFFFF (MAME's transparent value).
- rtl/mem/yb_fb_if.sv:6 Services (per DESIGN.md): - erase_line(y): fill line with 0xFFFF - write_run(...): pixel run writes from the sprite renderer; wr_shadow runs RMW dest &= 0x7fff instead (MAME shadow sprites clear framebuffer bit 15) - read_line(y):
- rtl/video/yb_bsprite_5196.sv:4 Algorithm: MAME sega16sp.cpp sega_sys16b_sprite_device::draw with the Y Board's origin (x 184 = screen 0), no screen flip, identity bank table: w0: bottom - 1 (15:8), top - 1 (7:0) w1: ----iiii -xxxxxxxx x (9 bits), iiii Y Board prio
- rtl/video/yb_bsprite_5196.sv:13 This module takes a copy of the 4 KB list at `snap` (one clk per word) and works on the copy, so the CPU's RAM is never written and the picture is the list as it was at the snapshot (MAME renders at screen update).
- rtl/video/yb_palette_5242.sv:4 Palette word: bit 15 = effects select (1 hilight / 0 shadow), 14:12 = LSB of B/G/R, 11:8 B, 7:4 G, 3:0 R (MAME paletteram_w).
- rtl/video/yb_rotate_5306.sv:3 MAME segaic16.cpp rotate_draw: per frame currx += dxx * 27 (the 27 is MAME's calibration, open question 5), then per screen pixel tx += dxx, ty += dyx and per line currx += dxy, curry += dyy; the source pixel is ((ty >> 14) & 0x1FF, (tx >>
- rtl/video/yb_video_timing.sv:4 MAME: m_screen->set_raw(MASTER_CLOCK/8, 400, 0, 320, 262, 0, 224).
- rtl/video/yb_video_timing.sv:61 Sync widths follow the System 16-family convention used by MAME's screen layout: hsync from 336..367 (32 px), vsync lines 240..243 (4 lines).
- rtl/video/yb_ysprite_5305.sv:6 Algorithm: MAME sega16sp.cpp sega_yboard_sprite_device::draw: w0: e------- -------- end of list; -h-h---- hide; -----iii iiiiiiii indirection table address (/16 words) in sprite RAM w1: bbbb---- -------- bank 7:4 (only bit 4 used); ----xxxx
- rtl/video/yb_ysprite_5305.sv:22 Sequence: every frame the renderer erases the back buffer, walks the list from sprite RAM as it is, and the buffers swap at the next vblank (MAME renders the list at screen update).
- rtl/video/yb_ysprite_5305.sv:123 row base (MAME addr), advanced by pitch
- rtl/video/yb_ysprite_5305.sv:162 a 64-bit word as MAME sees it: pens from bit 63 down; the stream holds it as four 16-bit words, first word first
- rtl/video/yb_ysprite_5305.sv:319 bank wraps to the ROM size (MAME bank %= numbanks): one subtraction per clock, at most three (32 bank values, 8 banks or more)
- rtl/video/yb_ysprite_5305.sv:338 MAME clamps min up to the buffer's left edge and max down to its right edge; a min beyond the right edge simply draws nothing
- rtl/yb_core.sv:79 driving games: draw the gear indicator (MAME's pdrift.lay shifter) in the corner
- rtl/yb_core.sv:145 IPL2 is the 315-5306's "timer" line, one scanline wide at the descriptor's line (MAME 170); IPL4 is vblank, one line wide at 223; IPL6 when both are up.
- rtl/yb_core.sv:147 All three CPUs see the same lines (MAME update_irqs).
- rtl/yb_core.sv:149 the OSD debug page can override the descriptor's IRQ2 line (MAME's tuned 170 is not a measurement; its notes say 150-200 all run Power Drift)
- rtl/yb_core.sv:162 ---------------------------------------------------------------- watchdog MB3773: its 5 s timer restarts on every falling edge of /WDCL (port E bit 5, MAME write_line_ck) and issues a reset when it runs out.
- rtl/yb_core.sv:191 main 68000 RESET instruction -> sub CPUs reset (MAME m68k_reset_callback)
- rtl/yb_core.sv:243 ---- sound latch (082001, odd byte): MAME's generic latch with its data-pending line on the Z80's NMI: a write raises it, the Z80's read of port 40 clears it
- rtl/yb_core.sv:255 ---- 315-5296 and the MSM6253 (low byte lane) Port A: P1 (unused); port B (MAME's GENERAL, active low): bit 0 After Burner (G-LOC, Strike Fighter), 1 test, 2 service, 3 start, 4 button 1, 5 button 2 or Power Drift's gear shift (active high,
- rtl/yb_core.sv:303 The seven MAME channels are ADC 0-2 and the 74HC4052 inputs 0-3 on channel 3.
- rtl/yb_core.sv:304 Ranges follow MAME's PORT_MINMAX; the Y reversals come from the descriptor's adc_reverse (PORT_REVERSE).
- rtl/yb_core.sv:397 driving (mode 2): the wheel slews toward the pad at 6 counts a frame (about 0.4 s lock to lock, near MAME's keyboard ramp), because a real wheel has travel and an instant thumbstick map steered like ice skates; the pedals are the buttons or
- rtl/yb_core.sv:597 The CPU writes one while the 315-5306 scans the other; a read of 198000 swaps them (MAME rotate_control_r exchanges the RAM with its buffer) and returns FFFF.
- rtl/yb_core.sv:641 MAME's instructions are atomic; the board's PALs must span the gap as well.
- rtl/yb_core.sv:822 ================================================================ video (M4) 315-5312 mixer (MAME segaybd_v.cpp screen_update): the rotated Y layer is the base (palette index, priority); a 16B pixel wins when its priority nibble, shifted, is
- rtl/yb_core.sv:848 gear indicator for the driving games, MAME's pdrift.lay shifter drawn from its geometry: 16x30 at (303, 193), the knob at the top in low gear, blended at 5/8 for the layout's 0.6 alpha.
- rtl/yb_core.sv:874 crosshair overlay for the gamepad gun mode (P1 white, P2 yellow): the 0..255 positions map to the 320x224 screen as MAME's crosshairs do
- rtl/yb_pkg.sv:53 ---- per-game descriptor (first 64 bytes of the stream) ---------------- byte 0: game id (0 gforce2, 1 pdrift, 2 gloc, 3 rchase, 4 strkfgtr, 5 glocr360, 6 pdriftl) byte 1: flags: bit0 deluxe cabinet (motor board stub on port C / ADC) bit1 l
- README.md:18 | M1 | Three 68000s boot, shared RAM, math/IO/ADC chips pass unit tests, PC traces track MAME | done 2026-08-27, 415/553 M10K, traces 99.7% vs MAME on all three
- README.md:22 | M5 | Sound (Z80, YM2151, 315-5218 with the Y Board banking) | done 2026-08-28, 441/553 M10K, audio envelope 0.969 vs MAME's recording, music and samples on ha
- README.md:26 | after | Power Drift's gear indicator (MAME's shifter overlay), wheel travel, "Stick re-center" option | done 2026-08-30, 442/553 M10K, confirmed on hardware (
- README.md:36 | Game | MAME set | ROM zips (MAME 0.289) | Controls |
- README.md:73 OSD options: Stick (D-pad by default, analog, or both), Analog response (Linear is the board's own mapping; Soft and Softer flatten the centre for thumbsticks w
- README.md:140 Needs Verilator, Icarus Verilog, Python 3.12 and MAME.
- README.md:243 **MAME** (mamedev.org) — the behavioural reference for the whole board: `segaybd.cpp` and the 16-bit Sega device family (`segaic16`, `sega16sp`), `segapcm.cpp`,
- README.md:245 Every custom chip model in `verif/models/` is a port of the MAME code, MAME 0.289 produced the golden frames, traces and audio the RTL is checked against, and P
MAMEと一致する、MAMEに合わせた、またはMAMEで確認したと記載 — 5
- README.md:21 | M4 | 315-5196 16B sprites and the 315-5312 mixer | done 2026-08-28, 429/553 M10K, frames pixel-exact vs MAME, attract complete on hardware |
- README.md:23 | M6 | Hardware bring-up: controls, NVRAM, DIPs, timing | done 2026-08-28, 441/553 M10K, test menu and Scene Select pixel-exact vs MAME, controls and 30 minutes
- README.md:24 | M7 | Power Drift, G-LOC, G-LOC R360, Rail Chase, Strike Fighter | done 2026-08-29, 441/553 M10K, all five attract modes match MAME at frames 150 and 300 (Rail
- README.md:58 Every game has been played on a DE10-Nano except Strike Fighter, which so far is verified pixel-exact against MAME in simulation only.
- README.md:169 What the tests show: the custom chips are checked against Python ports of MAME's C++ (the 315-5248/5249 over random operations, the 315-5296 and MSM6253 against
MAMEの近似をそのまま採用 — 1
- rtl/yb_pkg.sv:16 ---- video timing: 400 x 262 at clk_sys/8, 320 x 224 visible ---------- MAME's 342 columns are a set_size placeholder (open question 1).
MAMEドライバと同じ文言を含む(出典の明記なし) — 3