void cdda_device::device_start() { /* allocate an audio cache */ m_audio_cache = auto_alloc_array( machine(), UINT8, CD_MAX_SECTOR_DATA * MAX_SECTORS ); m_stream = machine().sound().stream_alloc(*this, 0, 2, 44100); m_audio_playing = 0; m_audio_pause = 0; m_audio_ended_normally = 0; m_audio_lba = 0; m_audio_length = 0; m_audio_samples = 0; m_audio_bptr = 0; m_disc = NULL; save_item( NAME(m_audio_playing) ); save_item( NAME(m_audio_pause) ); save_item( NAME(m_audio_ended_normally) ); save_item( NAME(m_audio_lba) ); save_item( NAME(m_audio_length) ); save_pointer( NAME(m_audio_cache), CD_MAX_SECTOR_DATA * MAX_SECTORS ); save_item( NAME(m_audio_samples) ); save_item( NAME(m_audio_bptr) ); }
void cloud9_state::video_start() { static const int resistances[3] = { 22000, 10000, 4700 }; /* allocate second bank of videoram */ m_videoram = std::make_unique<uint8_t[]>(0x8000); membank("bank1")->set_base(m_videoram.get()); /* get pointers to our PROMs */ m_syncprom = memregion("proms")->base() + 0x000; m_wpprom = memregion("proms")->base() + 0x200; m_priprom = memregion("proms")->base() + 0x300; /* compute the color output resistor weights at startup */ compute_resistor_weights(0, 255, -1.0, 3, resistances, m_rweights, 1000, 0, 3, resistances, m_gweights, 1000, 0, 3, resistances, m_bweights, 1000, 0); /* allocate a bitmap for drawing sprites */ m_screen->register_screen_bitmap(m_spritebitmap); /* register for savestates */ save_pointer(NAME(m_videoram.get()), 0x8000); save_item(NAME(m_video_control)); save_item(NAME(m_bitmode_addr)); }
void nixieclock_state::machine_start() { m_timer = 0; /* register for state saving */ save_item(NAME(m_timer)); save_pointer(NAME(m_nixie), 6); }
void c64_xl80_device::device_start() { // allocate memory c64_ram_pointer(machine(), RAM_SIZE); // state saving save_pointer(NAME(m_ram), RAM_SIZE); }
void pc8500_state::video_start() { /* allocate video memory */ m_video_ram = auto_alloc_array(m_machine, UINT8, PC8500_LCD_VIDEORAM_SIZE); /* register for state saving */ save_pointer(NAME(m_video_ram), PC8500_LCD_VIDEORAM_SIZE); }
void zeus2_device::device_start() { /* allocate memory for "wave" RAM */ waveram[0] = auto_alloc_array(machine(), UINT32, WAVERAM0_WIDTH * WAVERAM0_HEIGHT * 8/4); //waveram[1] = auto_alloc_array(machine(), UINT32, WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 12/4); m_frameColor = std::make_unique<UINT32[]>(WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 2); m_frameDepth = std::make_unique<UINT16[]>(WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 2); /* initialize polygon engine */ poly = auto_alloc(machine(), zeus2_renderer(this)); //m_screen = machine().first_screen(); m_screen = downcast<screen_device *>(machine().device("screen")); m_vblank.resolve_safe(); m_irq.resolve_safe(); /* we need to cleanup on exit */ //machine().add_notifier(MACHINE_NOTIFY_EXIT, machine_notify_delegate(FUNC(zeus2_device::exit_handler2), this)); int_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(zeus2_device::int_timer_callback), this)); vblank_timer = machine().scheduler().timer_alloc(timer_expired_delegate(FUNC(zeus2_device::display_irq), this)); /* save states */ save_pointer(NAME(waveram[0]), WAVERAM0_WIDTH * WAVERAM0_HEIGHT * 8 / sizeof(waveram[0][0])); //save_pointer(NAME(waveram[1]), WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 12 / sizeof(waveram[1][0])); save_pointer(NAME(m_frameColor.get()), WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 2); save_pointer(NAME(m_frameDepth.get()), WAVERAM1_WIDTH * WAVERAM1_HEIGHT * 2); save_item(NAME(m_zeusbase)); save_item(NAME(m_renderRegs)); save_item(NAME(zeus_fifo)); save_item(NAME(zeus_fifo_words)); save_item(NAME(zeus_cliprect.min_x)); save_item(NAME(zeus_cliprect.max_x)); save_item(NAME(zeus_cliprect.min_y)); save_item(NAME(zeus_cliprect.max_y)); save_item(NAME(zeus_matrix)); save_item(NAME(zeus_point)); save_item(NAME(zeus_point2)); save_item(NAME(zeus_texbase)); save_item(NAME(m_renderMode)); save_item(NAME(zeus_quad_size)); save_item(NAME(m_fill_color)); save_item(NAME(m_fill_depth)); save_item(NAME(m_renderPtr)); save_item(NAME(m_yScale)); }
INPUT_PORTS_END void harriet_state::machine_start() { m_zpram_data = std::make_unique<u8[]>(0x800); subdevice<nvram_device>("zpram")->set_base(m_zpram_data.get(), 0x800); save_pointer(NAME(m_zpram_data), 0x800); }
void psion_state::machine_start() { if (!strcmp(machine().system().name, "psionlam")) { m_rom_bank_count = 3; m_ram_bank_count = 0; } else if (!strcmp(machine().system().name, "psionp350")) { m_rom_bank_count = 0; m_ram_bank_count = 5; } else if (!strncmp(machine().system().name, "psionlz", 7)) { m_rom_bank_count = 3; m_ram_bank_count = 3; } else if (!strcmp(machine().system().name, "psionp464")) { m_rom_bank_count = 3; m_ram_bank_count = 9; } else { m_rom_bank_count = 0; m_ram_bank_count = 0; } if (m_rom_bank_count) { UINT8* rom_base = (UINT8 *)memregion("maincpu")->base(); membank("rombank")->configure_entry(0, rom_base + 0x8000); membank("rombank")->configure_entries(1, m_rom_bank_count-1, rom_base + 0x10000, 0x4000); membank("rombank")->set_entry(0); } if (m_ram_bank_count) { m_paged_ram = auto_alloc_array(machine(), UINT8, m_ram_bank_count * 0x4000); memset(m_paged_ram, 0, sizeof(UINT8) * (m_ram_bank_count * 0x4000)); membank("rambank")->configure_entries(0, m_ram_bank_count, m_paged_ram, 0x4000); membank("rambank")->set_entry(0); } save_item(NAME(m_kb_counter)); save_item(NAME(m_enable_nmi)); save_item(NAME(m_tcsr_value)); save_item(NAME(m_stby_pwr)); save_item(NAME(m_pulse)); save_item(NAME(m_rom_bank)); save_item(NAME(m_ram_bank)); save_item(NAME(m_port2_ddr)); save_item(NAME(m_port2)); save_item(NAME(m_port6_ddr)); save_item(NAME(m_port6)); save_pointer(NAME(m_paged_ram), m_ram_bank_count * 0x4000); }
GFXDECODE_END void slotcarn_state::machine_start() { m_ram_palette = auto_alloc_array(machine(), UINT8, RAM_PALETTE_SIZE); save_pointer(NAME(m_ram_palette), RAM_PALETTE_SIZE); }
void c64_xl80_device::device_start() { // find memory regions m_char_rom = memregion(HD46505SP_TAG)->base(); c64_ram_pointer(machine(), RAM_SIZE); // state saving save_pointer(NAME(m_ram), RAM_SIZE); }
void naomi_m2_board::device_start() { naomi_board::device_start(); ram = auto_alloc_array(machine(), UINT8, RAM_SIZE); save_item(NAME(rom_cur_address)); save_pointer(NAME(ram), RAM_SIZE); }
void tc0110pcr_device::device_start() { m_ram = auto_alloc_array_clear(machine(), UINT16, TC0110PCR_RAM_SIZE); save_pointer(NAME(m_ram), TC0110PCR_RAM_SIZE); save_item(NAME(m_type)); machine().save().register_postload(save_prepost_delegate(FUNC(tc0110pcr_device::restore_colors), this)); }
void v1050_state::video_start() { /* allocate memory */ m_attr_ram = auto_alloc_array(machine(), UINT8, V1050_VIDEORAM_SIZE); /* register for state saving */ save_item(NAME(m_attr)); save_pointer(NAME(m_attr_ram), V1050_VIDEORAM_SIZE); }
INPUT_PORTS_END VIDEO_START_MEMBER(vegaeo_state,vega) { m_vega_vram = auto_alloc_array(machine(), UINT32, 0x14000*2/4); save_pointer(NAME(m_vega_vram), 0x14000*2/4); save_item(NAME(m_vega_vbuffer)); }
void taito_zoom_device::device_start() { m_snd_shared_ram = auto_alloc_array_clear(machine(), UINT8, 0x100); // register for savestates save_item(NAME(m_reg_address)); save_item(NAME(m_tms_ctrl)); save_pointer(NAME(m_snd_shared_ram), 0x100); }
void deco156_state::video_start() { m_spriteram = std::make_unique<UINT16[]>(0x2000/2); /* and register the allocated ram so that save states still work */ save_item(NAME(m_pf1_rowscroll)); save_item(NAME(m_pf2_rowscroll)); save_pointer(NAME(m_spriteram.get()), 0x2000/2); }
void eeprom_base_device::device_start() { uint32_t size = (m_data_bits == 8 ? 1 : 2) << m_address_bits; m_data = std::make_unique<uint8_t []>(size); // save states save_item(NAME(m_completion_time)); save_pointer(m_data.get(), "m_data", size); }
VIDEO_START_MEMBER(leland_state,ataxx) { /* first do the standard stuff */ m_video_ram = make_unique_clear<uint8_t[]>(VRAM_SIZE); /* allocate memory */ m_ataxx_qram = make_unique_clear<uint8_t[]>(QRAM_SIZE); save_pointer(NAME(m_video_ram.get()), VRAM_SIZE); save_pointer(NAME(m_ataxx_qram.get()), QRAM_SIZE); save_item(NAME(m_xscroll)); save_item(NAME(m_yscroll)); for (uint8_t i = 0; i < 2; i++) { save_item(NAME(m_vram_state[i].m_addr), i); save_item(NAME(m_vram_state[i].m_latch), i); } }
void nes_fukutake_device::device_start() { common_start(); save_item(NAME(m_latch)); // 2816 (?) bytes of RAM m_ram = auto_alloc_array_clear(machine(), UINT8, 0xb00); save_pointer(NAME(m_ram), 0xb00); }
void naomi_m2_board::device_start() { naomi_board::device_start(); ram = std::make_unique<uint8_t[]>(RAM_SIZE); save_item(NAME(rom_cur_address)); save_pointer(NAME(ram.get()), RAM_SIZE); }
INPUT_PORTS_END void c65_state::machine_start() { m_iplrom = memregion("maincpu")->base(); save_pointer(NAME(m_cram.target()), 0x800); }
void taito_zoom_device::device_start() { m_snd_shared_ram = make_unique_clear<UINT8[]>(0x100); // register for savestates save_item(NAME(m_reg_address)); save_item(NAME(m_tms_ctrl)); save_pointer(NAME(m_snd_shared_ram.get()), 0x100); }
void deco156_state::video_start() { m_spriteram = auto_alloc_array(machine(), UINT16, 0x2000/2); /* and register the allocated ram so that save states still work */ save_item(NAME(m_pf1_rowscroll)); save_item(NAME(m_pf2_rowscroll)); save_pointer(NAME(m_spriteram), 0x2000/2); }
void odyssey2_state::machine_start() { save_pointer(NAME(m_ram),256); save_item(NAME(m_p1)); save_item(NAME(m_p2)); save_item(NAME(m_cart_size)); save_item(NAME(m_lum)); save_item(NAME(m_the_voice_lrq_state)); }
void beezer_state::machine_start() { // configure rom banks for (int i = 0; i < 7; i++) m_rombank[i]->configure_entries(0, 2, m_banked_roms->base() + (i * 0x2000), 0x1000); // allocate timers m_timer_count = timer_alloc(0); // register for state saving save_pointer(NAME(m_ch_sign), 4); save_pointer(NAME(m_dac_data), 4); save_item(NAME(m_count)); save_item(NAME(m_noise)); save_item(NAME(m_pbus)); save_item(NAME(m_x)); save_item(NAME(m_y)); save_item(NAME(m_z)); }
void vp590_device::device_start() { // allocate memory m_color_ram = auto_alloc_array(machine(), UINT8, COLOR_RAM_SIZE); // state saving save_pointer(NAME(m_color_ram), COLOR_RAM_SIZE); save_item(NAME(m_color)); save_item(NAME(m_keylatch)); }
void comx_clm_device::device_start() { m_rom = memregion("c000")->base(); m_char_rom = memregion(MC6845_TAG)->base(); m_video_ram = auto_alloc_array(machine(), UINT8, VIDEORAM_SIZE); // state saving save_item(NAME(m_ds)); save_pointer(NAME(m_video_ram), VIDEORAM_SIZE); }
void tmc2000e_state::machine_start() { /* allocate color RAM */ m_colorram = auto_alloc_array(m_machine, UINT8, TMC2000E_COLORRAM_SIZE); /* register for state saving */ save_pointer(NAME(m_colorram), TMC2000E_COLORRAM_SIZE); save_item(NAME(m_cdp1864_efx)); save_item(NAME(m_keylatch)); }
void tk02_device::device_start() { // setup ram m_ram = std::make_unique<uint8_t[]>(0x800); memset(m_ram.get(), 0xff, 0x800); // register for save states save_pointer(NAME(m_ram), 0x800); save_item(NAME(m_de)); }
void intelfsh_device::device_start() { m_data = std::make_unique<uint8_t []>(m_size); m_timer = timer_alloc(); save_item( NAME(m_status) ); save_item( NAME(m_flash_mode) ); save_item( NAME(m_flash_master_lock) ); save_pointer( &m_data[0], "m_data", m_size); }