summaryrefslogtreecommitdiffstatshomepage
path: root/src/devices/cpu/tms9900/tms9980a.h
blob: 8a7a409f2b88572f88d24480b72a42bd4eb144da (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
// license:BSD-3-Clause
// copyright-holders:Michael Zapf
/*
    TMS9980A.
    See tms9980a.c and tms9900.c for documentation
*/

#ifndef __TMS9980A_H__
#define __TMS9980A_H__

#include "emu.h"
#include "debugger.h"
#include "tms9900.h"

enum
{
	INT_9980A_RESET = 0,
	INT_9980A_LOAD = 2,
	INT_9980A_LEVEL1 = 3,
	INT_9980A_LEVEL2 = 4,
	INT_9980A_LEVEL3 = 5,
	INT_9980A_LEVEL4 = 6,
	INT_9980A_CLEAR= 7
};

class tms9980a_device : public tms99xx_device
{
public:
	tms9980a_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock);

protected:
	void        mem_read(void) override;
	void        mem_write(void) override;
	void        acquire_instruction(void) override;

	void        resolve_lines() override;

	uint16_t      read_workspace_register_debug(int reg) override;
	void        write_workspace_register_debug(int reg, uint16_t data) override;

	uint32_t      execute_min_cycles() const override;
	uint32_t      execute_max_cycles() const override;
	uint32_t      execute_input_lines() const override;
	void        execute_set_input(int irqline, int state) override;

	uint32_t      disasm_min_opcode_bytes() const override;
	uint32_t      disasm_max_opcode_bytes() const override;
	offs_t      disasm_disassemble(std::ostream &stream, offs_t pc, const uint8_t *oprom, const uint8_t *opram, uint32_t options) override;
	address_space_config    m_program_config80;
	address_space_config    m_io_config80;
};

// device type definition
extern const device_type TMS9980A;

#endif /* __TMS9980A_H__ */