misc: change my habit on where to place class variables

This commit is contained in:
hap 2023-11-25 20:11:17 +01:00
parent 0fb5c65784
commit 700ccfb69b
143 changed files with 716 additions and 693 deletions

View File

@ -44,12 +44,12 @@ private:
required_device<cpu_device> m_maincpu;
required_device_array<generic_latch_8_device, 2> m_latch;
u8 m_control = 0;
u8 internal_rom_r(offs_t offset) { return m_exrom[offset]; }
void chess_io(address_map &map);
void chess_mem(address_map &map);
u8 m_control = 0;
};
// device type definition

View File

@ -49,16 +49,16 @@ private:
required_device_array<generic_latch_8_device, 2> m_latch;
required_device<cassette_image_device> m_cass;
std::unique_ptr<u8[]> m_ram;
u8 m_control = 0;
bool m_installed = false;
void internal_io_w(offs_t offset, u8 data);
u8 internal_io_r(offs_t offset);
u8 internal_rom_r(offs_t offset) { return m_exrom[offset]; }
void homecomp_io(address_map &map);
void homecomp_mem(address_map &map);
std::unique_ptr<u8[]> m_ram;
u8 m_control = 0;
bool m_installed = false;
};
// device type definition

View File

@ -88,8 +88,6 @@ private:
devcb_write_line m_stb_handler;
devcb_write_line m_rts_handler;
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
// input pins state
u8 m_data = 0;
int m_nmi = 0;
@ -97,6 +95,8 @@ private:
int m_pw = 0;
device_saitekosa_expansion_interface *m_module;
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
};
// ======================> device_saitekosa_expansion_interface

View File

@ -48,6 +48,10 @@ protected:
required_memory_bank m_rombank;
required_device<generic_slot_device> m_extrom;
u8 m_latch = 0xff;
bool m_latch_enable = false;
u8 m_extrom_bank = 0;
virtual void main_map(address_map &map);
u8 extrom_r(offs_t offset);
@ -59,10 +63,6 @@ protected:
void control_w(u8 data);
void set_cpu_freq();
u8 m_latch = 0xff;
bool m_latch_enable = false;
u8 m_extrom_bank = 0;
};
class saitekosa_analyst_device : public saitekosa_maestro_device

View File

@ -39,6 +39,9 @@ protected:
private:
required_device<cpu_device> m_maincpu;
u8 m_latch = 0xff;
bool m_latch_enable = false;
void main_map(address_map &map);
u8 rts_r();
@ -48,9 +51,6 @@ private:
void control_w(u8 data);
void set_cpu_freq();
u8 m_latch = 0xff;
bool m_latch_enable = false;
};

View File

@ -41,6 +41,11 @@ private:
required_region_ptr<u32> m_rom;
required_shared_ptr<u32> m_ram;
u32 m_data_out = 0;
u32 m_rom_mask = 0;
u32 m_ram_mask = 0;
bool m_installed = false;
void debugger_map(address_map &map);
u32 rom_r(offs_t offset, u32 mem_mask) { return m_rom[offset & m_rom_mask]; }
@ -50,11 +55,6 @@ private:
void host_io_w(offs_t offset, u32 data, u32 mem_mask = ~0U);
void set_ram_mask(u8 n) { m_ram_mask = ((1 << n) / 4) - 1; }
u32 m_data_out = 0;
u32 m_rom_mask = 0;
u32 m_ram_mask = 0;
bool m_installed = false;
};
#endif // MAME_BUS_SAITEKOSA_SPARC_H

View File

@ -47,11 +47,12 @@ private:
devcb_write_line m_data_out;
u8 m_latch[2];
bool m_bootrom_enabled;
void data0_w_sync(int param);
void data1_w_sync(int param);
void reset_w_sync(int param);
bool m_bootrom_enabled;
void install_bootrom(bool enable);
TIMER_DEVICE_CALLBACK_MEMBER(disable_bootrom) { install_bootrom(false); }
u32 disable_bootrom_r();

View File

@ -56,6 +56,9 @@ private:
required_device<pwm_display_device> m_display;
required_ioport_array<4> m_inputs;
u8 m_io[2] = { };
u8 m_4042 = 0;
void main_map(address_map &map);
void main_io(address_map &map);
@ -65,9 +68,6 @@ private:
void mux_w(u8 data);
void digit_w(u8 data);
u8 input_r();
u8 m_io[2] = { };
u8 m_4042 = 0;
};
void boris_state::machine_start()

View File

@ -52,6 +52,11 @@ private:
required_device<pwm_display_device> m_display;
required_ioport_array<4> m_inputs;
std::unique_ptr<u8[]> m_ram;
u8 m_ram_address = 0;
u8 m_matrix = 0;
u8 m_digit_data = 0;
void main_map(address_map &map);
void main_io(address_map &map);
@ -65,11 +70,6 @@ private:
void ram_address_w(u8 data) { m_ram_address = data; }
u8 ram_data_r() { return m_ram[m_ram_address]; }
void ram_data_w(u8 data) { m_ram[m_ram_address] = data; }
std::unique_ptr<u8[]> m_ram;
u8 m_ram_address = 0;
u8 m_matrix = 0;
u8 m_digit_data = 0;
};
void borisdpl_state::machine_start()

View File

@ -111,6 +111,14 @@ private:
output_finder<2, 6> m_fdigit;
required_ioport_array<4+3> m_inputs;
u8 m_inp_mux = 0;
u16 m_digit_data = 0;
u8 m_shift_data = 0;
u8 m_shift_clock = 0;
bool m_extram_enabled = false;
u8 m_overlay = 0;
void main_map(address_map &map);
void update_reset(ioport_value state);
@ -129,14 +137,6 @@ private:
void shift_clock_w(int state);
void shift_data_w(int state);
u8 m_inp_mux = 0;
u16 m_digit_data = 0;
u8 m_shift_data = 0;
u8 m_shift_clock = 0;
bool m_extram_enabled = false;
u8 m_overlay = 0;
};
void ggm_state::machine_start()

View File

@ -108,6 +108,11 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
u8 m_select = 0;
u8 m_led_data = 0;
u8 m_shift_data = 0;
u8 m_shift_clock = 0;
void main_map(address_map &map);
// I/O handlers
@ -118,11 +123,6 @@ private:
void shift_clock_w(int state);
void shift_data_w(int state);
u8 m_select = 0;
u8 m_led_data = 0;
u8 m_shift_data = 0;
u8 m_shift_clock = 0;
};
void prodigy_state::machine_start()

View File

@ -60,12 +60,12 @@ private:
required_device<pwm_display_device> m_display;
required_ioport_array<6> m_inputs;
u32 m_r = 0;
u16 m_o = 0;
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
u32 m_r = 0;
u16 m_o = 0;
};
void hitpar_state::machine_start()

View File

@ -98,24 +98,24 @@ private:
optional_device<generic_slot_device> m_cart;
required_ioport_array<2> m_inputs;
u16 m_inp_mux = 0;
u16 m_led_select = 0;
u8 m_led_group = 0;
u8 m_led_latch = 0;
u16 m_led_data = 0;
bool m_altboard = false;
void main_map(address_map &map);
void v2_map(address_map &map);
void init_board(int state);
bool m_altboard = false;
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
void update_display();
void leds_w(u8 data);
void control_w(u8 data);
u8 input_r();
u16 m_inp_mux = 0;
u16 m_led_select = 0;
u8 m_led_group = 0;
u8 m_led_latch = 0;
u16 m_led_data = 0;
};
void arb_state::machine_start()

View File

@ -66,6 +66,8 @@ private:
required_device<address_map_bank_device> m_mainmap;
required_ioport_array<2> m_inputs;
u8 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
void main_trampoline(address_map &map);
@ -75,8 +77,6 @@ private:
// I/O handlers
u8 input_r();
void control_w(u8 data);
u8 m_inp_mux = 0;
};

View File

@ -151,6 +151,11 @@ private:
optional_device<beep_device> m_beeper;
required_ioport_array<4> m_inputs;
u8 m_inp_mux = 0;
u8 m_digit_select = 0;
u8 m_digit_data = 0;
bool m_blink = false;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -173,11 +178,6 @@ private:
void input_digit_select_w(u8 data) { input_w(data); digit_select_w(data); }
void input_digit_data_w(u8 data) { input_w(data); digit_data_w(data); }
u8 m_inp_mux = 0;
u8 m_digit_select = 0;
u8 m_digit_data = 0;
bool m_blink = false;
};

View File

@ -112,6 +112,8 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<2> m_inputs;
u8 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
@ -120,8 +122,6 @@ private:
u8 input_r();
void leds_w(offs_t offset, u8 data);
void sound_w(u8 data);
u8 m_inp_mux = 0;
};
void conchess_state::machine_start()

View File

@ -73,6 +73,10 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<8> m_inputs;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
int m_dac_on = 0;
// address maps
void main_map(address_map &map);
@ -84,10 +88,6 @@ private:
u8 pia1_pa_r();
u8 pia1_pb_r();
void pia1_pb_w(u8 data);
u8 m_inp_mux = 0;
u8 m_led_data = 0;
int m_dac_on = 0;
};
void cchess2_state::machine_start()

View File

@ -69,6 +69,10 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
bool m_power = false;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
// address maps
void main_map(address_map &map);
@ -77,10 +81,6 @@ private:
void control_w(u8 data);
void leds_w(u8 data);
u8 input_r();
bool m_power = false;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
};
void regence_state::machine_start()

View File

@ -110,6 +110,12 @@ private:
required_ioport_array<4> m_inputs;
output_finder<2> m_out_leds;
bool m_bootrom_enabled = false;
u32 m_control = 0;
u32 m_prev_pc = 0;
u64 m_prev_cycle = 0;
void main_map(address_map &map);
// I/O handlers
@ -123,11 +129,6 @@ private:
void set_cpu_freq();
void install_bootrom(bool enable);
TIMER_DEVICE_CALLBACK_MEMBER(disable_bootrom) { install_bootrom(false); }
bool m_bootrom_enabled = false;
u32 m_control = 0;
u32 m_prev_pc = 0;
u64 m_prev_cycle = 0;
};
void tasc_state::machine_start()

View File

@ -70,6 +70,10 @@ private:
output_finder<8> m_out_digit;
output_finder<64> m_out_lcd;
u8 m_led_data = 0;
u8 m_cb_mux = 0xff;
u8 m_control = 0xff;
// address maps
void main_map(address_map &map);
@ -80,10 +84,6 @@ private:
void cb_w(u8 data);
void led_w(u8 data);
void control_w(offs_t offset, u8 data);
u8 m_led_data = 0;
u8 m_cb_mux = 0xff;
u8 m_control = 0xff;
};
void y532xl_state::machine_start()

View File

@ -88,6 +88,10 @@ private:
required_device<dac_bit_interface> m_dac;
optional_ioport_array<5> m_inputs;
u8 m_inp_mux = 0;
u8 m_7seg_data = 0;
u8 m_led_data = 0;
// address maps
void main_map(address_map &map);
@ -96,10 +100,6 @@ private:
void control_w(u8 data);
void digit_w(u8 data);
u8 input_r();
u8 m_inp_mux = 0;
u8 m_7seg_data = 0;
u8 m_led_data = 0;
};
void chmate_state::machine_start()

View File

@ -114,6 +114,12 @@ private:
required_ioport_array<3> m_row;
required_ioport m_special;
int m_sync_state = 0;
bool m_k7 = false;
uint8_t m_u2_port_b = 0;
uint8_t m_311_output = 0;
uint32_t m_cassette_high_count = 0;
void mem_map(address_map &map);
void sync_map(address_map &map);
@ -126,12 +132,6 @@ private:
void u2_write_b(uint8_t data);
TIMER_DEVICE_CALLBACK_MEMBER(cassette_input);
int m_sync_state = 0;
bool m_k7 = false;
uint8_t m_u2_port_b = 0;
uint8_t m_311_output = 0;
uint32_t m_cassette_high_count = 0;
};
void kim1_state::machine_start()

View File

@ -62,6 +62,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
u16 m_inp_mux = 0;
int m_dac_data = 0;
// address maps
void main_map(address_map &map);
@ -69,9 +72,6 @@ private:
void speaker_w(u8 data);
void leds_w(u8 data);
u8 input_r();
u16 m_inp_mux = 0;
int m_dac_data = 0;
};
void ch2001_state::machine_start()

View File

@ -98,13 +98,13 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
void update_display();
template<int N> void mux_w(u8 data);
void leds_w(u16 data);
u16 input_r();
u8 m_inp_mux = 0;
u8 m_led_data = 0;
};
void scptchess_state::machine_start()

View File

@ -17,8 +17,8 @@ TODO:
Hardware notes:
- PCB label (Super Crown): CXG 218-600-001
- Hitachi HD6301Y0 @ 8MHz
- 2KB battery-backed RAM
- Hitachi HD6301Y0 (mode 2), 8MHz XTAL
- 2KB battery-backed RAM (HM6116LP-3)
- chessboard buttons, 24 LEDs, piezo
210 MCU is used in:
@ -76,6 +76,8 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
u8 m_inp_mux = 0;
void main_map(address_map &map);
// I/O handlers
@ -83,8 +85,6 @@ private:
u8 input2_r();
void control_w(u8 data);
void mux_w(u8 data);
u8 m_inp_mux = 0;
};
void senterp_state::machine_start()

View File

@ -93,6 +93,10 @@ private:
output_finder<8> m_out_digit;
output_finder<64> m_out_lcd;
u8 m_cb_mux = 0;
u8 m_led_data = 0;
u8 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
@ -110,10 +114,6 @@ private:
u8 nvram_r(offs_t offset) { return m_nvram[offset]; }
void nvram_w(offs_t offset, u8 data) { m_nvram[offset] = data; }
u8 m_cb_mux = 0;
u8 m_led_data = 0;
u8 m_inp_mux = 0;
};
void sphinx40_state::machine_start()

View File

@ -74,6 +74,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
u16 m_matrix = 0;
u8 m_led_data[2] = { 0, 0 };
void chessmst_io(address_map &map);
void chessmst_mem(address_map &map);
@ -83,9 +86,6 @@ private:
void pio2_port_b_w(u8 data);
void update_leds();
u16 m_matrix = 0;
u8 m_led_data[2] = { 0, 0 };
};
void chessmst_state::machine_start()

View File

@ -78,6 +78,13 @@ private:
required_ioport_array<2> m_inputs;
output_finder<4> m_digits;
u16 m_matrix = 0;
u8 m_led_data = 0;
u8 m_direct_leds = 0;
u8 m_digit_matrix = 0;
int m_digit_dot = 0;
u16 m_digit_data = 0;
void chessmstdm_mem(address_map &map);
void chessmstdm_io(address_map &map);
@ -91,13 +98,6 @@ private:
void update_leds();
void update_digits();
u16 m_matrix = 0;
u8 m_led_data = 0;
u8 m_direct_leds = 0;
u8 m_digit_matrix = 0;
int m_digit_dot = 0;
u16 m_digit_data = 0;
};
void chessmstdm_state::machine_start()

View File

@ -105,6 +105,8 @@ private:
required_ioport_array<6> m_inputs;
output_finder<> m_halt_led;
u8 m_matrix = 0;
void lc80_mem(address_map &map);
void lc80a_mem(address_map &map);
void lc80e_mem(address_map &map);
@ -119,8 +121,6 @@ private:
u8 pio1_pb_r();
void pio1_pb_w(u8 data);
u8 pio2_pb_r();
u8 m_matrix = 0;
};

View File

@ -90,6 +90,9 @@ private:
required_device<cassette_image_device> m_cassette;
required_ioport_array<3> m_inputs;
u8 m_matrix = 0;
bool m_nmi = false;
void poly880_io(address_map &map);
void poly880_mem(address_map &map);
void poly880s_mem(address_map &map);
@ -100,9 +103,6 @@ private:
void pio1_pa_w(u8 data);
u8 pio1_pb_r();
void pio1_pb_w(u8 data);
u8 m_matrix = 0;
bool m_nmi = false;
};

View File

@ -71,12 +71,12 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<4> m_inputs;
void main_io(address_map &map);
void main_map(address_map &map);
u8 m_inp_mux = 0;
u8 m_digit_data = 0;
void main_io(address_map &map);
void main_map(address_map &map);
void update_display();
u8 pio_port_b_r();
void pio_port_a_w(u8 data);

View File

@ -95,14 +95,14 @@ private:
required_device<pwm_display_device> m_display;
output_finder<> m_busyled;
u8 m_select = 0;
u8 m_segment = 0;
void mem_map(address_map &map);
void io_map(address_map &map);
u8 input_r();
void control_w(offs_t offset, u8 data);
u8 m_select = 0;
u8 m_segment = 0;
};
void slc1_state::machine_start()

View File

@ -83,6 +83,10 @@ private:
optional_device<hd44780_device> m_lcd;
required_ioport_array<4> m_inputs;
u8 m_inp_mux = 0;
u8 m_shift_reg = 0;
int m_shift_clk = 0;
// address maps
void main_map(address_map &map);
void data_map(address_map &map);
@ -95,10 +99,6 @@ private:
void lcd_w(u8 data);
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
u8 m_inp_mux = 0;
u8 m_shift_reg = 0;
int m_shift_clk = 0;
};
void avrmax_state::machine_start()

View File

@ -98,6 +98,21 @@ private:
required_ioport m_joy;
required_ioport m_conf;
static constexpr u32 DISPLAY_WIDTH = 0x400;
bool m_video_strobe = false;
bool m_video_enable = false;
u8 m_video_bank = 0;
u32 m_video_hpos = 0;
u8 m_led_output[5] = { };
u8 m_led_latch[5] = { };
std::unique_ptr<u8[]> m_display;
memory_region *m_cart_rom = nullptr;
std::vector<u8> m_ext_ram;
u16 m_rambank = 0;
u8 m_sound_cmd = 0;
void io_map(address_map &map);
void program_map(address_map &map);
@ -117,21 +132,6 @@ private:
u8 ext_ram_r(offs_t offset);
void ext_ram_w(offs_t offset, u8 data);
u8 controller_r();
static constexpr u32 DISPLAY_WIDTH = 0x400;
bool m_video_strobe = false;
bool m_video_enable = false;
u8 m_video_bank = 0;
u32 m_video_hpos = 0;
u8 m_led_output[5] = { };
u8 m_led_latch[5] = { };
std::unique_ptr<u8[]> m_display;
memory_region *m_cart_rom = nullptr;
std::vector<u8> m_ext_ram;
u16 m_rambank = 0;
u8 m_sound_cmd = 0;
};

View File

@ -66,14 +66,14 @@ private:
required_device<generic_slot_device> m_cart;
required_ioport_array<6> m_inputs;
u16 m_grid = 0;
u16 m_plate = 0;
void update_display();
u8 input_r();
void speaker_w(int state);
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
u16 m_grid = 0;
u16 m_plate = 0;
void hmcs40_write_r(offs_t offset, u8 data);
void hmcs40_write_d(u16 data);
u16 hmcs40_read_d();

View File

@ -56,15 +56,15 @@ private:
required_device<speaker_sound_device> m_speaker;
required_ioport_array<2> m_inputs;
u8 m_control = 0;
u8 m_lcd_data = 0;
void control_w(u8 data);
void lcd_data_w(u8 data);
u8 input_r();
u32 screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void main_map(address_map &map);
u8 m_control = 0;
u8 m_lcd_data = 0;
};
void gamepock_state::machine_start()

View File

@ -82,6 +82,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u16 m_inp_mux = 0;
u8 m_led_data = 0;
// address maps
void main_map(address_map &map);
@ -90,9 +93,6 @@ private:
void control_w(u8 data);
void led_w(offs_t offset, u8 data);
u8 input_r(offs_t offset);
u16 m_inp_mux = 0;
u8 m_led_data = 0;
};
void as12_state::machine_start()

View File

@ -66,6 +66,8 @@ private:
required_ioport_array<8> m_inputs;
output_finder<12> m_digits;
u8 m_inp_mux = 0;
void main_map(address_map &map);
void main_io(address_map &map);
@ -76,8 +78,6 @@ private:
u8 input_r();
void input_w(u8 data);
void update_pa();
u8 m_inp_mux = 0;
};
void bridgeb_state::machine_start()

View File

@ -228,14 +228,15 @@ private:
optional_device<dac_bit_interface> m_dac;
required_ioport_array<8> m_inputs;
u32 m_barcode = 0;
u16 m_vfd_data = 0;
u8 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
TIMER_DEVICE_CALLBACK_MEMBER(barcode_shift) { m_barcode >>= 1; }
u32 m_barcode = 0;
u16 m_vfd_data = 0;
u8 m_inp_mux = 0;
// I/O handlers
void update_display();

View File

@ -104,6 +104,9 @@ private:
optional_device<timer_device> m_delay;
required_ioport_array<2> m_inputs;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -114,9 +117,6 @@ private:
u8 ppi_porta_r();
void ppi_portb_w(u8 data);
void ppi_portc_w(u8 data);
u8 m_led_select = 0;
u8 m_7seg_data = 0;
};
void cc1_state::machine_start()

View File

@ -78,7 +78,9 @@ private:
optional_device<beep_device> m_beeper;
required_ioport_array<4> m_inputs;
TIMER_DEVICE_CALLBACK_MEMBER(beeper_off) { m_beeper->set_state(0); }
u8 m_inp_mux = 0;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
// address maps
void acr_map(address_map &map);
@ -89,16 +91,14 @@ private:
u8 main_trampoline_r(offs_t offset);
void main_trampoline_w(offs_t offset, u8 data);
TIMER_DEVICE_CALLBACK_MEMBER(beeper_off) { m_beeper->set_state(0); }
// I/O handlers
void update_display();
void ppi_porta_w(u8 data);
void ppi_portb_w(u8 data);
u8 ppi_portc_r();
void ppi_portc_w(u8 data);
u8 m_inp_mux = 0;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
};
void ccx_state::machine_start()

View File

@ -86,6 +86,9 @@ private:
optional_device<dac_bit_interface> m_dac;
required_ioport_array<4> m_inputs;
u8 m_inp_mux = 0;
u8 m_7seg_data = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -93,9 +96,6 @@ private:
// I/O handlers
u8 input_r();
void control_w(offs_t offset, u8 data);
u8 m_inp_mux = 0;
u8 m_7seg_data = 0;
};
void bcc_state::machine_start()

View File

@ -52,6 +52,15 @@ private:
required_device<pwm_display_device> m_display;
required_ioport_array<4> m_inputs;
u8 m_ram[0x100] = { };
u8 m_ram_address = 0;
u8 m_ram_data = 0;
u8 m_ram_control = 0;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
// I/O handlers
void update_display();
void segsel_w(u8 data);
@ -63,15 +72,6 @@ private:
void rama0_w(u8 data);
void rama1_w(u8 data);
u8 input_r();
u8 m_ram[0x100] = { };
u8 m_ram_address = 0;
u8 m_ram_data = 0;
u8 m_ram_control = 0;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
};
void cr_state::machine_start()

View File

@ -71,16 +71,16 @@ private:
required_device<pwm_display_device> m_display;
required_ioport m_inputs;
int m_numbanks = 0;
u8 m_speech_bank = 0;
u8 m_select = 0;
// address maps
void main_map(address_map &map);
// I/O handlers
void control_w(offs_t offset, u8 data);
u8 input_r(offs_t offset);
int m_numbanks = 0;
u8 m_speech_bank = 0;
u8 m_select = 0;
};
void chesster_state::init_chesster()

View File

@ -34,14 +34,14 @@ protected:
void div_refresh(ioport_value val = 0xff);
private:
inline void div_set_cpu_freq(offs_t offset);
memory_passthrough_handler m_read_tap;
memory_passthrough_handler m_write_tap;
u16 m_div_status = 0;
double m_div_scale = 0;
emu_timer *m_div_timer = nullptr;
inline void div_set_cpu_freq(offs_t offset);
};

View File

@ -266,6 +266,11 @@ protected:
optional_region_ptr<u8> m_language;
optional_ioport_array<9> m_inputs;
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
// address maps
void csc_map(address_map &map);
void csce_map(address_map &map);
@ -287,11 +292,6 @@ protected:
void pia1_pb_w(u8 data);
u8 pia1_pb_r();
void pia1_ca2_w(int state);
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
};
void csc_state::machine_start()

View File

@ -64,6 +64,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
// address maps
void main_map(address_map &map);
@ -75,9 +78,6 @@ private:
void init_board(int state);
u8 read_board_row(u8 row);
u8 m_inp_mux = 0;
u8 m_led_select = 0;
};
void dsc_state::machine_start()

View File

@ -88,6 +88,9 @@ protected:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_select = 0;
u32 m_lcd_data = 0;
// address maps
void fdes2100d_map(address_map &map);
@ -96,9 +99,6 @@ protected:
virtual void control_w(offs_t offset, u8 data);
virtual void lcd_w(offs_t offset, u8 data);
virtual u8 input_r(offs_t offset);
u8 m_select = 0;
u32 m_lcd_data = 0;
};
void desdis_state::init_fdes2100d()

View File

@ -273,6 +273,11 @@ protected:
required_device<dac_bit_interface> m_dac;
optional_ioport_array<3> m_inputs;
bool m_rotate = true;
u8 m_select = 0;
u8 m_7seg_data = 0;
u8 m_led_data = 0;
// address maps
void eag_map(address_map &map);
void eagv7_map(address_map &map);
@ -285,11 +290,6 @@ protected:
u8 input_r(offs_t offset);
void leds_w(offs_t offset, u8 data);
void digit_w(offs_t offset, u8 data);
bool m_rotate = true;
u8 m_select = 0;
u8 m_7seg_data = 0;
u8 m_led_data = 0;
};
void eag_state::machine_start()

View File

@ -56,6 +56,10 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
bool m_kp_select = false;
u16 m_inp_mux = 0;
u8 m_led_select = 0;
// I/O handlers
void update_display();
void mux_w(u8 data);
@ -63,10 +67,6 @@ private:
void control_w(u8 data);
int t0_r();
u8 input_r();
bool m_kp_select = false;
u16 m_inp_mux = 0;
u8 m_led_select = 0;
};
void eldorado_state::machine_start()

View File

@ -137,6 +137,12 @@ protected:
required_region_ptr<u8> m_language;
required_ioport_array<2> m_inputs;
bool m_rotate = false;
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
// address maps
void eas_map(address_map &map);
void pc_map(address_map &map);
@ -150,12 +156,6 @@ protected:
void ppi_porta_w(u8 data);
u8 ppi_portb_r();
void ppi_portc_w(u8 data);
bool m_rotate = false;
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
};
void elite_state::machine_start()

View File

@ -192,6 +192,11 @@ private:
optional_region_ptr<u8> m_speech_rom;
optional_ioport_array<3> m_inputs;
u8 m_select = 0;
u8 m_7seg_data = 0;
u8 m_speech_data = 0;
u8 m_speech_bank = 0;
// address maps
void fexcel_map(address_map &map);
void fexcelb_map(address_map &map);
@ -200,11 +205,6 @@ private:
u8 speech_r(offs_t offset);
void ttl_w(offs_t offset, u8 data);
u8 ttl_r(offs_t offset);
u8 m_select = 0;
u8 m_7seg_data = 0;
u8 m_speech_data = 0;
u8 m_speech_bank = 0;
};
void excel_state::machine_start()

View File

@ -68,6 +68,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_led_select = 0;
u16 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
@ -80,9 +83,6 @@ private:
u8 read_inputs();
u8 input_hi_r();
u8 input_lo_r();
u8 m_led_select = 0;
u16 m_inp_mux = 0;
};
void msc_state::machine_start()

View File

@ -98,6 +98,19 @@ protected:
output_finder<5> m_out_motor;
output_finder<2> m_out_pos;
u8 m_mux = 0;
u8 m_select = 0;
u32 m_lcd_data = 0;
u8 m_motors_ctrl = 0;
int m_hmotor_pos = 0;
int m_vmotor_pos = 0;
bool m_vmotor_sensor0_ff = false;
bool m_vmotor_sensor1_ff = false;
bool m_hmotor_sensor0_ff = false;
bool m_hmotor_sensor1_ff = false;
u8 m_pieces_map[0x80][0x80] = { };
// address maps
virtual void main_map(address_map &map);
@ -117,19 +130,6 @@ protected:
TIMER_DEVICE_CALLBACK_MEMBER(motors_timer);
void update_pieces_position(int state);
void output_magnet_pos();
u8 m_mux = 0;
u8 m_select = 0;
u32 m_lcd_data = 0;
u8 m_motors_ctrl = 0;
int m_hmotor_pos = 0;
int m_vmotor_pos = 0;
bool m_vmotor_sensor0_ff = false;
bool m_vmotor_sensor1_ff = false;
bool m_hmotor_sensor0_ff = false;
bool m_hmotor_sensor1_ff = false;
u8 m_pieces_map[0x80][0x80] = { };
};
void phantom_state::machine_start()

View File

@ -103,14 +103,14 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_inp_mux = 0;
// address maps
void main_map(address_map &map);
// I/O handlers
void control_w(u8 data);
u8 input_r(offs_t offset);
u8 m_inp_mux = 0;
};
void sc12_state::machine_start()

View File

@ -123,6 +123,9 @@ private:
optional_device<generic_slot_device> m_cart;
required_ioport m_inputs;
u8 m_led_select = 0;
u8 m_inp_mux = 0;
// address maps
void msc_map(address_map &map);
void sc6_map(address_map &map);
@ -137,9 +140,6 @@ private:
u8 input_r();
int input6_r();
int input7_r();
u8 m_led_select = 0;
u8 m_inp_mux = 0;
};
void sc6_state::machine_start()

View File

@ -63,6 +63,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -70,9 +73,6 @@ private:
// I/O handlers
u8 input_r();
void control_w(offs_t offset, u8 data);
u8 m_inp_mux = 0;
u8 m_led_data = 0;
};
void scc_state::machine_start()

View File

@ -94,6 +94,9 @@ protected:
required_device<dac_bit_interface> m_dac;
required_ioport m_inputs;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
// address maps
void sc9_map(address_map &map);
void sc9d_map(address_map &map);
@ -104,9 +107,6 @@ protected:
void led_w(offs_t offset, u8 data);
u8 input_r();
u8 input_d7_r(offs_t offset);
u8 m_inp_mux = 0;
u8 m_led_data = 0;
};
void sc9_state::machine_start()

View File

@ -150,6 +150,11 @@ private:
required_region_ptr<u8> m_language;
required_ioport_array<4> m_inputs;
u8 m_led_select = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -162,11 +167,6 @@ private:
void ppi_portb_w(u8 data);
u8 ppi_portc_r();
void ppi_portc_w(u8 data);
u8 m_led_select = 0;
u8 m_7seg_data = 0;
u8 m_inp_mux = 0;
u8 m_speech_bank = 0;
};
void vcc_state::machine_start()

View File

@ -199,6 +199,13 @@ private:
required_region_ptr<u8> m_language;
required_ioport_array<2> m_inputs;
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_cb_mux = 0;
u8 m_kp_mux = 0;
bool m_lan_switch = false;
u8 m_speech_bank = 0;
// address maps
void main_map(address_map &map);
void main_io(address_map &map);
@ -214,13 +221,6 @@ private:
u8 pio_porta_r();
u8 pio_portb_r();
void pio_portb_w(u8 data);
u8 m_led_data = 0;
u8 m_7seg_data = 0;
u8 m_cb_mux = 0;
u8 m_kp_mux = 0;
bool m_lan_switch = false;
u8 m_speech_bank = 0;
};
void vsc_state::machine_start()

View File

@ -74,6 +74,10 @@ private:
required_device<beep_device> m_beeper;
required_device<generic_slot_device> m_cart;
uint8_t m_3f_data = 0;
uint8_t m_cart_bank = 0;
uint16_t m_beeper_freq = 0;
void chesskng_map(address_map &map);
void chesskng_io(address_map &map);
@ -96,10 +100,6 @@ private:
void unk_6f_w(uint8_t data);
uint32_t screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
uint8_t m_3f_data = 0;
uint8_t m_cart_bank = 0;
uint16_t m_beeper_freq = 0;
};
void chessking_state::machine_start()

View File

@ -80,6 +80,8 @@ private:
required_device<screen_device> m_screen;
required_device<speaker_sound_device> m_speaker;
u8 m_chipsel = 0;
u8 io_r(offs_t offset);
void io_w(offs_t offset, u8 data);
void portb_w(u8 data);
@ -88,8 +90,6 @@ private:
template<int N> SED1520_UPDATE_CB(screen_update_cb);
void main_map(address_map &map);
u8 m_chipsel = 0;
};
void gmaster_state::machine_start()

View File

@ -358,6 +358,7 @@ public:
private:
required_device<ds8874_device> m_ds8874;
void ds8874_output_w(u16 data);
void update_display();
@ -710,6 +711,7 @@ public:
private:
required_device<ds8874_device> m_ds8874;
void ds8874_output_w(u16 data);
void update_display();

View File

@ -2433,13 +2433,14 @@ protected:
private:
required_device<filter_volume_device> m_volume;
double m_speaker_volume = 0.0;
void update_display();
void plate_w(offs_t offset, u8 data);
void grid_w(u16 data);
void speaker_update();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void cdkong_state::machine_start()
@ -3355,6 +3356,8 @@ protected:
required_device<cop411_cpu_device> m_audiocpu;
u8 m_cop_irq = 0;
void set_clock();
void update_int();
virtual void update_display();
@ -3365,8 +3368,6 @@ protected:
void cop_irq_w(u8 data);
u8 cop_latch_r();
u8 cop_ack_r();
u8 m_cop_irq = 0;
};
void eturtles_state::machine_start()

View File

@ -874,6 +874,8 @@ protected:
private:
required_device<filter_volume_device> m_volume;
double m_speaker_volume = 0.0;
void update_display();
void write_b(u8 data);
u8 read_c();
@ -881,7 +883,6 @@ private:
void speaker_update();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void flash_state::machine_start()
@ -1318,13 +1319,14 @@ protected:
private:
required_device<filter_volume_device> m_volume;
double m_speaker_volume = 0.0;
u8 read_a();
void write_b(u8 data);
void write_c(u8 data);
void speaker_update();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void leboom_state::machine_start()

View File

@ -6754,8 +6754,8 @@ protected:
private:
// R2 connects to a single LED behind the screen
void led_w(u8 data) { m_led_out = data >> 1 & 1; }
output_finder<> m_led_out;
void led_w(u8 data) { m_led_out = data >> 1 & 1; }
};
void tgaiden_state::machine_start()

View File

@ -987,13 +987,13 @@ protected:
virtual void machine_start() override;
private:
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
output_finder<> m_motor1;
output_finder<> m_motor2_left;
output_finder<> m_motor2_right;
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
};
void bcheetah_state::machine_start()
@ -1873,12 +1873,13 @@ private:
required_device<filter_volume_device> m_volume;
required_device<timer_device> m_tempo_timer;
double m_speaker_volume = 0.0;
void write_o(u16 data);
void write_r(u32 data);
u8 read_k();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void cchime_state::machine_start()
@ -3097,8 +3098,8 @@ protected:
virtual void machine_start() override;
private:
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
u16 m_pinout = 0x07; // cartridge R pins
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
void update_display();
void write_r(u32 data);
@ -3288,8 +3289,8 @@ protected:
virtual void machine_start() override;
private:
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
u8 m_pinout = 0xf; // cartridge K pins
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
void update_display();
void write_r(u32 data);
@ -3471,12 +3472,13 @@ protected:
private:
required_device<filter_volume_device> m_volume;
double m_speaker_volume = 0.0;
void write_o(u16 data);
void write_r(u32 data);
u8 read_k();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void litelrn_state::machine_start()
@ -4026,6 +4028,7 @@ public:
private:
required_device<ds8874_device> m_ds8874;
void ds8874_output_w(u16 data);
void update_display();
@ -5994,13 +5997,14 @@ private:
required_device<filter_volume_device> m_volume;
required_device<timer_device> m_speed_timer;
double m_speaker_volume = 0.0;
void update_display();
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
};
void mmarvin_state::machine_start()
@ -7005,6 +7009,7 @@ public:
private:
required_device<tms1024_device> m_expander;
void expander_w(offs_t offset, u8 data);
void update_display();
@ -7458,17 +7463,17 @@ protected:
virtual void machine_start() override;
private:
std::unique_ptr<u16[]> m_display;
u8 m_led_data[2] = { };
u16 m_wand_pos[2] = { };
attotime m_shake;
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
TIMER_DEVICE_CALLBACK_MEMBER(check_pos);
std::unique_ptr<u16[]> m_display;
u8 m_led_data[2] = { };
u16 m_wand_pos[2] = { };
attotime m_shake;
};
void skywriter_state::machine_start()
@ -9679,20 +9684,21 @@ protected:
virtual void machine_start() override;
private:
void update_speaker();
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
TIMER_DEVICE_CALLBACK_MEMBER(gearbox_sim_tick);
bool sensor_state() { return m_gearbox_pos < 0 && m_display->element_on(0, 0); }
int m_gearbox_pos = 0;
output_finder<> m_left_motor_forward;
output_finder<> m_left_motor_reverse;
output_finder<> m_right_motor_forward;
output_finder<> m_right_motor_reverse;
output_finder<> m_ext_out;
int m_gearbox_pos = 0;
TIMER_DEVICE_CALLBACK_MEMBER(gearbox_sim_tick);
bool sensor_state() { return m_gearbox_pos < 0 && m_display->element_on(0, 0); }
void update_speaker();
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
};
void bigtrak_state::machine_start()
@ -9903,9 +9909,6 @@ protected:
virtual void machine_start() override;
private:
void update_display();
bool sensor_led_on() { return m_display->element_on(0, 0); }
output_finder<> m_motor_pos_out;
output_finder<> m_card_pos_out;
output_finder<> m_motor_on_out;
@ -9916,6 +9919,9 @@ private:
bool m_motor_on = false;
bool m_sensor_blind = false;
void update_display();
bool sensor_led_on() { return m_display->element_on(0, 0); }
TIMER_DEVICE_CALLBACK_MEMBER(motor_sim_tick);
void write_r(u32 data);
@ -12325,15 +12331,15 @@ private:
required_device<tms5110_device> m_tms5100;
required_device<tms6100_device> m_tms6100;
attotime m_pulse;
u8 m_dial = 0;
u8 m_ram_address = 0;
void write_r(u32 data);
void write_o(u16 data);
u8 read_k();
TIMER_DEVICE_CALLBACK_MEMBER(sense_weight);
attotime m_pulse;
u8 m_dial = 0;
u8 m_ram_address = 0;
};
void wtalker_state::machine_start()
@ -15225,8 +15231,8 @@ protected:
virtual void machine_start() override;
private:
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
u8 m_notch = 0; // cartridge K1/K2
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
void update_display();
void write_r(u32 data);
@ -16254,6 +16260,7 @@ protected:
private:
required_device<tms1025_device> m_expander;
u8 m_exp_port[7] = { };
void expander_w(offs_t offset, u8 data);
void set_clock();
@ -16693,6 +16700,7 @@ public:
private:
required_device<tms1024_device> m_expander;
void expander_w(offs_t offset, u8 data);
void update_display();

View File

@ -69,6 +69,14 @@ private:
required_ioport_array<8> m_inputs;
output_finder<16> m_digits;
u8 m_p0 = 0;
u8 m_p1 = 0;
u8 m_p4 = 0;
u8 m_p5 = 0;
bool m_has_ram = false;
u8 m_ram[0x400];
void main_map(address_map &map);
void main_io(address_map &map);
@ -83,14 +91,6 @@ private:
void p4_w(u8 data);
u8 p5_r();
void p5_w(u8 data);
u8 m_p0 = 0;
u8 m_p1 = 0;
u8 m_p4 = 0;
u8 m_p5 = 0;
bool m_has_ram = false;
u8 m_ram[0x400];
};
void lk3000_state::machine_start()

View File

@ -69,6 +69,10 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<6> m_inputs;
u64 m_lcd_data[32] = { };
int m_lcd_cs = 0;
int m_halt = 0;
void monty_mem(address_map &map);
void mmonty_mem(address_map &map);
void monty_io(address_map &map);
@ -80,10 +84,6 @@ private:
void lcd_w(offs_t offset, u8 data) { m_lcd[m_lcd_cs]->write(offset, data); }
u8 input_r(offs_t offset);
void halt_changed(int state) { m_halt = state; }
u64 m_lcd_data[32] = { };
int m_lcd_cs = 0;
int m_halt = 0;
};
void monty_state::machine_start()

View File

@ -51,13 +51,13 @@ private:
required_device<speaker_sound_device> m_speaker;
required_ioport_array<5> m_inputs;
u8 m_inp_mux = 0;
u16 m_r = 0;
void write_o(u8 data);
void write_p(u8 data);
template<int N> u8 read_r();
template<int N> void write_r(u8 data);
u8 m_inp_mux = 0;
u16 m_r = 0;
};
void scrablex_state::machine_start()

View File

@ -140,12 +140,12 @@ private:
required_device<pwm_display_device> m_display;
required_ioport_array<5> m_inputs;
void main_map(address_map &map);
void main_io(address_map &map);
u8 m_bank = 0;
u8 m_inp_mux = 0;
void main_map(address_map &map);
void main_io(address_map &map);
// I/O handlers
void bank_w(u8 data);
u8 bank_r(offs_t offset);

View File

@ -58,12 +58,12 @@ private:
required_region_ptr<u8> m_rom;
required_ioport_array<5> m_inputs;
void main_map(address_map &map);
void main_io(address_map &map);
u8 m_bank = 0;
u8 m_inp_mux = 0;
void main_map(address_map &map);
void main_io(address_map &map);
// I/O handlers
void bank_w(u8 data);
template<int Psen> u8 bank_r(offs_t offset);

View File

@ -56,6 +56,12 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<3> m_inputs;
u8 m_inp_sel = 0;
u8 m_input = 0;
u8 m_sound = 0;
u8 m_select = 0;
u8 m_led_data = 0;
void main_map(address_map &map);
void main_io(address_map &map);
@ -67,12 +73,6 @@ private:
u8 input_r();
void sound_w(u8 data);
u8 sound_r();
u8 m_inp_sel = 0;
u8 m_input = 0;
u8 m_sound = 0;
u8 m_select = 0;
u8 m_led_data = 0;
};
void teammate_state::machine_start()

View File

@ -73,16 +73,17 @@ private:
required_device<speaker_sound_device> m_speaker;
required_device<filter_volume_device> m_volume;
u16 m_a = 0;
u8 m_d = 0;
double m_speaker_volume = 0.0;
void update_display();
void write_d(u8 data);
void write_a(u16 data);
void speaker_update();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_decay_sim);
double m_speaker_volume = 0.0;
u16 m_a = 0;
u8 m_d = 0;
};
void wildfire_state::machine_start()

View File

@ -135,6 +135,11 @@ private:
required_device<timer_device> m_speaker_off;
optional_ioport_array<4+2> m_inputs;
bool m_reset = false;
u8 m_esb_led = 0;
u8 m_esb_row = 0;
u8 m_esb_select = 0;
// address maps
void mephisto_map(address_map &map);
void mephistoj_map(address_map &map);
@ -156,11 +161,6 @@ private:
int esb_r();
TIMER_DEVICE_CALLBACK_MEMBER(speaker_off) { m_dac->write(0); }
bool m_reset = false;
u8 m_esb_led = 0;
u8 m_esb_row = 0;
u8 m_esb_select = 0;
};

View File

@ -73,13 +73,13 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_keys;
u8 m_kp_mux = 0;
void glasgow_mem(address_map &map);
void control_w(u8 data);
u8 keys_r();
void keys_w(u8 data);
u8 m_kp_mux = 0;
};
void glasgow_state::machine_start()

View File

@ -55,6 +55,9 @@ private:
required_device<pwm_display_device> m_led_pwm;
required_ioport m_keys;
u8 m_board_mux = 0;
u8 m_led_data = 0;
void milano_mem(address_map &map);
void update_leds();
@ -62,9 +65,6 @@ private:
void board_w(u8 data);
u8 board_r();
u8 keys_r(offs_t offset);
u8 m_board_mux = 0;
u8 m_led_data = 0;
};
void milano_state::machine_start()

View File

@ -85,6 +85,9 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<2> m_inputs;
bool m_reset = false;
u8 m_kp_mux = 0;
// address maps
void mirage_map(address_map &map);
void mm1_map(address_map &map);
@ -97,9 +100,6 @@ private:
void unknown_w(u8 data);
void keypad_w(u8 data);
template<int N> int keypad_r();
bool m_reset = false;
u8 m_kp_mux = 0;
};
void mm1_state::machine_start()

View File

@ -33,11 +33,11 @@ private:
output_finder<4> m_digits;
devcb_write8 m_output_digit;
void update_lcd();
int m_strobe;
u8 m_digit_idx;
u8 m_digit_data[4];
void update_lcd();
};

View File

@ -39,11 +39,11 @@ private:
required_device<hd44780_device> m_lcd;
required_device<speaker_sound_device> m_dac;
void lcd_palette(palette_device &palette) const;
HD44780_PIXEL_UPDATE(lcd_pixel_update);
u8 m_latch;
u8 m_ctrl;
void lcd_palette(palette_device &palette) const;
HD44780_PIXEL_UPDATE(lcd_pixel_update);
};

View File

@ -62,15 +62,15 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport m_keys;
u8 m_board_mux = 0;
u8 m_io_ctrl = 0;
void modena_mem(address_map &map);
u8 input_r();
void io_w(u8 data);
void led_w(u8 data);
void update_display();
u8 m_board_mux = 0;
u8 m_io_ctrl = 0;
};
void modena_state::machine_start()

View File

@ -140,6 +140,8 @@ private:
required_device<timer_device> m_bav_busy;
optional_ioport m_fake;
u8 m_bav_data = 0;
// address maps
void alm16_mem(address_map &map);
void alm32_mem(address_map &map);
@ -160,8 +162,6 @@ private:
u8 spawn_cb(offs_t offset);
void set_sbtype(ioport_value newval);
u8 m_bav_data = 0;
};
void mmodular_state::machine_start()

View File

@ -88,6 +88,8 @@ private:
required_device<timer_device> m_disable_bootrom;
optional_ioport m_fake;
bool m_bootrom_enabled = false;
// address maps
void mmtm_2m_map(address_map &map);
void mmtm_8m_map(address_map &map);
@ -97,7 +99,6 @@ private:
void install_bootrom(bool enable);
TIMER_DEVICE_CALLBACK_MEMBER(disable_bootrom) { install_bootrom(false); }
bool m_bootrom_enabled = false;
void set_cpu_freq();
};

View File

@ -57,13 +57,13 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<2> m_keys;
u8 m_inp_mux = 0;
void mondial_mem(address_map &map);
void control_w(u8 data);
u8 irq_ack_r();
u8 input_r(offs_t offset);
u8 m_inp_mux = 0;
};
void mondial_state::machine_start()

View File

@ -52,16 +52,16 @@ private:
required_device<dac_bit_interface> m_dac;
required_ioport_array<4> m_keys;
u8 m_keypad_mux = 0;
u8 m_board_mux = 0;
u8 m_led_data = 0;
void mondial2_mem(address_map &map);
void update_leds();
void control_w(u8 data);
void board_w(u8 data);
u8 input_r(offs_t offset);
u8 m_keypad_mux = 0;
u8 m_board_mux = 0;
u8 m_led_data = 0;
};
void mondial2_state::machine_start()

View File

@ -56,14 +56,6 @@ protected:
virtual void machine_start() override;
private:
void mondial68k_mem(address_map &map);
void update_leds();
void lcd_output_w(u32 data);
void input_mux_w(u8 data);
void board_mux_w(u8 data);
u8 inputs_r();
required_device<cpu_device> m_maincpu;
required_device<sensorboard_device> m_board;
required_device<hc259_device> m_lcd_latch;
@ -74,6 +66,14 @@ private:
u8 m_input_mux = 0xff;
u8 m_board_mux = 0xff;
void mondial68k_mem(address_map &map);
void update_leds();
void lcd_output_w(u32 data);
void input_mux_w(u8 data);
void board_mux_w(u8 data);
u8 inputs_r();
};
void mondial68k_state::machine_start()

View File

@ -77,6 +77,9 @@ protected:
required_ioport_array<4> m_keys;
output_finder<8> m_digits;
u8 m_led_data = 0;
u8 m_board_mux = 0;
// address maps
void smondialb_mem(address_map &map);
void smondial2_mem(address_map &map);
@ -88,9 +91,6 @@ protected:
virtual void led_w(u8 data);
void board_w(u8 data);
INTERRUPT_GEN_MEMBER(nmi_handler);
u8 m_led_data = 0;
u8 m_board_mux = 0;
};
void smondialb_state::machine_start()

View File

@ -111,6 +111,11 @@ private:
required_device<hc55516_device> m_cvsd;
required_region_ptr<u8> m_samplerom;
tilemap_t *m_bg_tilemap = nullptr;
u16 m_soundcmd = 0;
u8 m_sample_latch = 0;
u16 m_sample_address = 0;
// video-related
void videoram_w(offs_t offset, u8 data);
void colorram_w(offs_t offset, u8 data);
@ -131,11 +136,6 @@ private:
void main_map(address_map &map);
void sound_map(address_map &map);
tilemap_t *m_bg_tilemap = nullptr;
u16 m_soundcmd = 0;
u8 m_sample_latch = 0;
u16 m_sample_address = 0;
};
void olibochu_state::machine_start()

View File

@ -516,23 +516,23 @@ license:CC0-1.0
<rect state="1"><color red="0.65" green="0.65" blue="0.66" /></rect>
</element>
<element name="text_l1"><text string="NEW GAME" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l2"><text string="ENTER POSITION" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l3"><text string="SOUND/COLOR" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l4"><text string="LIBRARY/CLEARBOARD" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l5"><text string="REPLAY" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l6"><text string="HINT" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l7"><text string="LEVEL" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l8"><text string="MULTI MOVE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l9"><text string="TAKE BACK" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l10"><text string="MOVE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l1"><text string="NEW GAME" align="2"></text></element>
<element name="text_l2"><text string="ENTER POSITION" align="2"></text></element>
<element name="text_l3"><text string="SOUND/COLOR" align="2"></text></element>
<element name="text_l4"><text string="LIBRARY/CLEARBOARD" align="2"></text></element>
<element name="text_l5"><text string="REPLAY" align="2"></text></element>
<element name="text_l6"><text string="HINT" align="2"></text></element>
<element name="text_l7"><text string="LEVEL" align="2"></text></element>
<element name="text_l8"><text string="MULTI MOVE" align="2"></text></element>
<element name="text_l9"><text string="TAKE BACK" align="2"></text></element>
<element name="text_l10"><text string="MOVE" align="2"></text></element>
<element name="text_l11"><text string="ERROR" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l12"><text string="CHECK" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l13"><text string="MATE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l14"><text string="DRAW" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l15"><text string="3RD REPET" align="2"><color red="1" green="1" blue="1" /></text></element> <!-- sic -->
<element name="text_l16"><text string="RESIGN" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l11"><text string="ERROR" align="2"></text></element>
<element name="text_l12"><text string="CHECK" align="2"></text></element>
<element name="text_l13"><text string="MATE" align="2"></text></element>
<element name="text_l14"><text string="DRAW" align="2"></text></element>
<element name="text_l15"><text string="3RD REPET" align="2"></text></element> <!-- sic -->
<element name="text_l16"><text string="RESIGN" align="2"></text></element>
<element name="text_p1"><image file="chess/wk.svg"/></element>
<element name="text_p2"><image file="chess/wq.svg"/></element>

View File

@ -479,23 +479,23 @@ license:CC0-1.0
<rect state="1"><color red="0.65" green="0.65" blue="0.66" /></rect>
</element>
<element name="text_l1"><text string="NEW GAME" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l2"><text string="ENTER POSITION" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l3"><text string="SOUND/COLOR" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l4"><text string="LIBRARY/CLEARBOARD" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l5"><text string="TIME" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l6"><text string="HINT" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l7"><text string="LEVEL" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l8"><text string="MULTI MOVE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l9"><text string="TAKE BACK" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l10"><text string="MOVE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l1"><text string="NEW GAME" align="2"></text></element>
<element name="text_l2"><text string="ENTER POSITION" align="2"></text></element>
<element name="text_l3"><text string="SOUND/COLOR" align="2"></text></element>
<element name="text_l4"><text string="LIBRARY/CLEARBOARD" align="2"></text></element>
<element name="text_l5"><text string="TIME" align="2"></text></element>
<element name="text_l6"><text string="HINT" align="2"></text></element>
<element name="text_l7"><text string="LEVEL" align="2"></text></element>
<element name="text_l8"><text string="MULTI MOVE" align="2"></text></element>
<element name="text_l9"><text string="TAKE BACK" align="2"></text></element>
<element name="text_l10"><text string="MOVE" align="2"></text></element>
<element name="text_l11"><text string="ERROR" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l12"><text string="CHECK" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l13"><text string="MATE" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l14"><text string="DRAW" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l15"><text string="3RD REPET" align="2"><color red="1" green="1" blue="1" /></text></element> <!-- sic -->
<element name="text_l16"><text string="RESIGN" align="2"><color red="1" green="1" blue="1" /></text></element>
<element name="text_l11"><text string="ERROR" align="2"></text></element>
<element name="text_l12"><text string="CHECK" align="2"></text></element>
<element name="text_l13"><text string="MATE" align="2"></text></element>
<element name="text_l14"><text string="DRAW" align="2"></text></element>
<element name="text_l15"><text string="3RD REPET" align="2"></text></element> <!-- sic -->
<element name="text_l16"><text string="RESIGN" align="2"></text></element>
<element name="text_p1"><image file="chess/wk.svg"/></element>
<element name="text_p2"><image file="chess/wq.svg"/></element>

View File

@ -62,15 +62,15 @@ private:
required_ioport_array<4> m_inputs;
output_finder<2, 8, 22> m_out_x;
u8 m_inp_mux = 0;
u8 m_lcd_control = 0;
// I/O handlers
template<int Sel> void lcd_output_w(offs_t offset, u32 data);
void input_w(u8 data);
u8 input_r();
void lcd_w(u8 data);
u8 lcd_r();
u8 m_inp_mux = 0;
u8 m_lcd_control = 0;
};
void mchess_state::machine_start()

View File

@ -86,11 +86,11 @@ private:
// devices
required_device<cop420_cpu_device> m_maincpu;
u8 m_g = 0;
u8 read_g();
void write_g(u8 data);
void write_d(u8 data);
u8 m_g = 0;
};
void eva24_state::machine_start()

View File

@ -54,24 +54,25 @@ protected:
virtual void machine_start() override;
private:
void sound_w(uint8_t data);
void lamp1_w(uint8_t data);
void lamp2_w(uint8_t data);
int m_hopper_motor = 0;
int m_hopper_coin = 0;
emu_timer *m_hopper_timer = nullptr;
TIMER_CALLBACK_MEMBER(hopper_coinout);
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void mem_map(address_map &map);
void io_map(address_map &map);
required_device<cpu_device> m_maincpu;
required_shared_ptr<u8> m_p_videoram;
required_region_ptr<u8> m_p_chargen;
required_device<beep_device> m_beeper;
output_finder<6> m_lamps;
int m_hopper_motor = 0;
int m_hopper_coin = 0;
emu_timer *m_hopper_timer = nullptr;
void mem_map(address_map &map);
void io_map(address_map &map);
uint32_t screen_update(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect);
void sound_w(uint8_t data);
void lamp1_w(uint8_t data);
void lamp2_w(uint8_t data);
TIMER_CALLBACK_MEMBER(hopper_coinout);
};

View File

@ -76,6 +76,16 @@ private:
required_ioport_array<4> m_inputs;
output_finder<> m_led;
u8 m_porta = 0xff;
u8 m_portb = 0xff;
u8 m_portc = 0xff;
u8 m_efdata = 0xff;
u8 m_romlatch = 0;
u8 m_ccount = 0;
u8 m_command = 0;
u8 m_pixel_offset = 0;
u8 m_vramdata = 0;
DECLARE_DEVICE_IMAGE_LOAD_MEMBER(cart_load);
TIMER_DEVICE_CALLBACK_MEMBER(scanline) { m_ef9367->update_scanline(param); }
@ -92,16 +102,6 @@ private:
void portb_w(u8 data);
void portc_w(u8 data);
u8 portd_r();
u8 m_porta = 0xff;
u8 m_portb = 0xff;
u8 m_portc = 0xff;
u8 m_efdata = 0xff;
u8 m_romlatch = 0;
u8 m_ccount = 0;
u8 m_command = 0;
u8 m_pixel_offset = 0;
u8 m_vramdata = 0;
};

View File

@ -52,11 +52,11 @@ public:
void compmahj(machine_config &config);
private:
required_device<lh5801_cpu_device> m_maincpu;
void main_map(address_map &map);
void io_map(address_map &map);
required_device<lh5801_cpu_device> m_maincpu;
u8 ita_r();
};

View File

@ -77,6 +77,11 @@ private:
required_ioport_array<4> m_inputs;
output_finder<3> m_digits;
u16 m_counter = 0;
u8 m_sound_data = 0;
emu_timer *m_counter_timer;
emu_timer *m_beeper_off;
void main_map(address_map &map);
u32 screen_update(screen_device &screen, bitmap_rgb32 &bitmap, const rectangle &cliprect);
@ -87,11 +92,6 @@ private:
TIMER_CALLBACK_MEMBER(counter_tick);
TIMER_CALLBACK_MEMBER(beeper_off) { m_beeper->set_state(0); }
u16 m_counter = 0;
u8 m_sound_data = 0;
emu_timer *m_counter_timer;
emu_timer *m_beeper_off;
};
void cothello_state::machine_start()

View File

@ -67,6 +67,9 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<8> m_inputs;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
void set_cpu_freq();
// address maps
@ -78,9 +81,6 @@ private:
void control_w(u8 data);
u8 input1_r();
u8 input2_r();
u8 m_inp_mux = 0;
u8 m_led_select = 0;
};
void cexpert_state::machine_start()

View File

@ -65,6 +65,9 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<8> m_inputs;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
// address maps
void main_map(address_map &map);
@ -75,9 +78,6 @@ private:
void control_w(u8 data);
u8 input1_r();
u8 input2_r();
u8 m_inp_mux = 0;
u8 m_led_select = 0;
};
void cforte_state::machine_start()

View File

@ -127,6 +127,10 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<8> m_inputs;
bool m_power = false;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
// address maps
void const_map(address_map &map);
void ssensor4_map(address_map &map);
@ -138,10 +142,6 @@ private:
void control_w(u8 data);
u8 input1_r();
u8 input2_r();
bool m_power = false;
u8 m_inp_mux = 0;
u8 m_led_select = 0;
};
void const_state::machine_start()

View File

@ -76,6 +76,12 @@ private:
required_device<beep_device> m_beeper;
required_ioport_array<8> m_inputs;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
u8 m_led_side = 0;
u8 m_lcd_control = 0;
u8 m_lcd_data = 0;
// address maps
void diablo68k_map(address_map &map);
void scorpio68k_map(address_map &map);
@ -90,12 +96,6 @@ private:
HD44780_PIXEL_UPDATE(lcd_pixel_update);
void lcd_palette(palette_device &palette) const;
u8 m_inp_mux = 0;
u8 m_led_data = 0;
u8 m_led_side = 0;
u8 m_lcd_control = 0;
u8 m_lcd_data = 0;
};
void diablo_state::machine_start()

Some files were not shown because too many files have changed in this diff Show More