blob: 20d4b076413b6ca1f3260ecc2ce047a1f7a9dbf6 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
|
// license:BSD-3-Clause
// copyright-holders:Fabio Priuli
/***************************************************************************
Konami 033906
***************************************************************************/
#pragma once
#ifndef __K033906_H__
#define __K033906_H__
#include "emu.h"
#include "video/voodoo.h"
/***************************************************************************
DEVICE CONFIGURATION MACROS
***************************************************************************/
#define MCFG_K033906_VOODOO(_tag) \
k033906_device::set_voodoo_tag(*device, "^" _tag);
/***************************************************************************
TYPE DEFINITIONS
***************************************************************************/
// ======================> k033906_device
class k033906_device : public device_t
{
public:
// construction/destruction
k033906_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);
static void set_voodoo_tag(device_t &device, const char *tag) { downcast<k033906_device &>(device).m_voodoo.set_tag(tag); }
DECLARE_READ32_MEMBER( read );
DECLARE_WRITE32_MEMBER( write );
DECLARE_WRITE_LINE_MEMBER( set_reg );
protected:
// device-level overrides
virtual void device_start() override;
virtual void device_reset() override { }
virtual void device_post_load() override { }
virtual void device_clock_changed() override { }
private:
uint32_t reg_r(int reg);
void reg_w(int reg, uint32_t data);
/* i/o lines */
int m_reg_set; // 1 = access reg / 0 = access ram
required_device<voodoo_device> m_voodoo;
uint32_t m_reg[256];
uint32_t m_ram[32768];
};
// device type definition
extern const device_type K033906;
#endif /* __K033906_H__ */
|