本文整理汇总了C++中required_device::chip_select方法的典型用法代码示例。如果您正苦于以下问题:C++ required_device::chip_select方法的具体用法?C++ required_device::chip_select怎么用?C++ required_device::chip_select使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类required_device
的用法示例。
在下文中一共展示了required_device::chip_select方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: clickstart
INPUT_PORTS_END
// There is a SEEPROM on the motherboard (type?)
void clickstart_state::clickstart(machine_config &config)
{
UNSP(config, m_maincpu, XTAL(27'000'000));
m_maincpu->set_addrmap(AS_PROGRAM, &clickstart_state::mem_map);
SCREEN(config, m_screen, SCREEN_TYPE_RASTER);
m_screen->set_refresh_hz(60);
m_screen->set_size(320, 262);
m_screen->set_visarea(0, 320-1, 0, 240-1);
m_screen->set_screen_update("spg", FUNC(spg2xx_device::screen_update));
m_screen->screen_vblank().set(m_spg, FUNC(spg2xx_device::vblank));
SPEAKER(config, "lspeaker").front_left();
SPEAKER(config, "rspeaker").front_right();
SPG28X(config, m_spg, XTAL(27'000'000), m_maincpu, m_screen);
m_spg->porta_out().set(FUNC(clickstart_state::porta_w));
m_spg->portb_out().set(FUNC(clickstart_state::portb_w));
m_spg->portc_out().set(FUNC(clickstart_state::portc_w));
m_spg->porta_in().set(FUNC(clickstart_state::porta_r));
m_spg->portb_in().set(FUNC(clickstart_state::portb_r));
m_spg->portc_in().set(FUNC(clickstart_state::portc_r));
m_spg->adc_in<0>().set_constant(0x0fff);
m_spg->chip_select().set(FUNC(clickstart_state::chip_sel_w));
m_spg->add_route(ALL_OUTPUTS, "lspeaker", 0.5);
m_spg->add_route(ALL_OUTPUTS, "rspeaker", 0.5);
GENERIC_CARTSLOT(config, m_cart, generic_plain_slot, "clickstart_cart");
m_cart->set_width(GENERIC_ROM16_WIDTH);
m_cart->set_device_load(device_image_load_delegate(&clickstart_state::device_image_load_cart, this));
SOFTWARE_LIST(config, "cart_list").set_original("clickstart_cart");
}