1 // license:BSD-3-Clause 2 // copyright-holders:Zsolt Vasvari 3 /************************************************************************* 4 5 Hana Awase 6 7 *************************************************************************/ 8 #ifndef MAME_INCLUDES_HANAAWAS_H 9 #define MAME_INCLUDES_HANAAWAS_H 10 11 #pragma once 12 13 #include "emupal.h" 14 #include "tilemap.h" 15 16 class hanaawas_state : public driver_device 17 { 18 public: hanaawas_state(const machine_config & mconfig,device_type type,const char * tag)19 hanaawas_state(const machine_config &mconfig, device_type type, const char *tag) : 20 driver_device(mconfig, type, tag), 21 m_videoram(*this, "videoram"), 22 m_colorram(*this, "colorram"), 23 m_maincpu(*this, "maincpu"), 24 m_gfxdecode(*this, "gfxdecode") 25 { } 26 27 void hanaawas(machine_config &config); 28 29 private: 30 /* memory pointers */ 31 required_shared_ptr<uint8_t> m_videoram; 32 required_shared_ptr<uint8_t> m_colorram; 33 34 /* video-related */ 35 tilemap_t *m_bg_tilemap; 36 37 /* misc */ 38 int m_mux; 39 uint8_t m_coin_settings; 40 uint8_t m_coin_impulse; 41 uint8_t hanaawas_input_port_0_r(); 42 void hanaawas_inputs_mux_w(uint8_t data); 43 void hanaawas_videoram_w(offs_t offset, uint8_t data); 44 void hanaawas_colorram_w(offs_t offset, uint8_t data); 45 void key_matrix_status_w(uint8_t data); 46 void irq_ack_w(uint8_t data); 47 TILE_GET_INFO_MEMBER(get_bg_tile_info); 48 virtual void machine_start() override; 49 virtual void machine_reset() override; 50 virtual void video_start() override; 51 void hanaawas_palette(palette_device &palette) const; 52 uint32_t screen_update_hanaawas(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect); 53 void hanaawas_portB_w(uint8_t data); 54 required_device<cpu_device> m_maincpu; 55 required_device<gfxdecode_device> m_gfxdecode; 56 void hanaawas_map(address_map &map); 57 void io_map(address_map &map); 58 }; 59 60 #endif // MAME_INCLUDES_HANAAWAS_H 61