blob: 9b0f1c7544735d3a36794255050b5ee4d995a667 (
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
|
// license:BSD-3-Clause
// copyright-holders:R. Belmont, Olivier Galibert
// HD44780/LCD image combo used in the yamaha mu, vl70m, fs1r and
// probably others
#ifndef MAME_MACHINE_MULCD_H
#define MAME_MACHINE_MULCD_H
#pragma once
#include "video/hd44780.h"
#include "screen.h"
class mulcd_device : public device_t
{
public:
mulcd_device(const machine_config &mconfig, const char *tag, device_t *owner, uint32_t clock = 0);
void set_contrast(u8 contrast);
void set_leds(u8 leds);
u8 data_read() { return m_lcd->data_r(); }
u8 control_read() { return m_lcd->control_r(); }
void data_write(u8 data) { m_lcd->data_w(data); }
void control_write(u8 data) { m_lcd->control_w(data); }
protected:
virtual void device_start() override;
virtual void device_reset() override;
virtual const tiny_rom_entry *device_rom_region() const override;
virtual void device_add_mconfig(machine_config &config) override;
private:
required_device<hd44780_device> m_lcd;
output_finder<64, 8, 5> m_outputs;
output_finder<> m_contrast;
output_finder<6> m_led_outputs;
DECLARE_WRITE_LINE_MEMBER(render_w);
};
DECLARE_DEVICE_TYPE(MULCD, mulcd_device)
#endif
|