Skip to content

Commit

Permalink
jaleco/jaleco_vj_qtaro.cpp: Added preliminary King Qtaro PCI video de…
Browse files Browse the repository at this point in the history
…coder card device.

Video decoding is not implemented yet.
  • Loading branch information
987123879113 authored and cuavas committed Feb 19, 2024
1 parent 78b9d5d commit 1b9cdb3
Show file tree
Hide file tree
Showing 5 changed files with 673 additions and 5 deletions.
4 changes: 4 additions & 0 deletions src/mame/jaleco/jaleco_vj_pc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ jaleco_vj_pc_device::jaleco_vj_pc_device(const machine_config &mconfig, const ch
device_t(mconfig, JALECO_VJ_PC, tag, owner, clock),
device_mixer_interface(mconfig, *this, 2),
m_maincpu(*this, "maincpu"),
m_king_qtaro(*this, "pci:08.0"),
m_sound(*this, "isa1:vj_sound"),
m_is_steppingstage(false)
{
Expand Down Expand Up @@ -125,6 +126,9 @@ void jaleco_vj_pc_device::device_add_mconfig(machine_config &config)

// TODO: pci:07.3 0x30401106 VIA VT83C572, VT86C586/A/B Power Management Controller

JALECO_VJ_KING_QTARO(config, m_king_qtaro, 0);
m_king_qtaro->set_bus_master_space(m_maincpu, AS_PROGRAM); // FIXME: remove this workaround when PCI framework grows bus mastering support

// TODO: Should actually be pci:0a.0 but it only shows a black screen
PCI_SLOT(config, "pci:2", pci_cards, 16, 1, 2, 3, 0, "virgedx").set_fixed(true);

Expand Down
5 changes: 5 additions & 0 deletions src/mame/jaleco/jaleco_vj_pc.h
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

#pragma once

#include "jaleco_vj_qtaro.h"
#include "jaleco_vj_sound.h"

#include "cpu/i386/i386.h"
Expand All @@ -23,6 +24,9 @@ class jaleco_vj_pc_device :
void comm_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) { m_sound->comm_w(offset, data, mem_mask); }
void ymz_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) { m_sound->ymz_w(offset, data, mem_mask); }

template <int DeviceId> void video_mix_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) { m_king_qtaro->video_mix_w<DeviceId>(offset, data); }
void video_control_w(offs_t offset, uint16_t data, uint16_t mem_mask = ~0) { m_king_qtaro->video_control_w(offset, data); }

protected:
virtual const tiny_rom_entry *device_rom_region() const override ATTR_COLD;
virtual void device_add_mconfig(machine_config &config) override ATTR_COLD;
Expand All @@ -35,6 +39,7 @@ class jaleco_vj_pc_device :
void boot_state_w(uint8_t data);

required_device<pentium_device> m_maincpu;
required_device<jaleco_vj_king_qtaro_device> m_king_qtaro;
required_device<jaleco_vj_isa16_sound_device> m_sound;
bool m_is_steppingstage;
};
Expand Down
Loading

0 comments on commit 1b9cdb3

Please sign in to comment.