trunk/src/emu/bus/isa/svga_trident.c
| r0 | r31939 | |
| 1 | /* |
| 2 | * svga_trident.c |
| 3 | * |
| 4 | * Created on: 6/09/2014 |
| 5 | */ |
| 6 | |
| 7 | #include "emu.h" |
| 8 | #include "svga_trident.h" |
| 9 | #include "video/pc_vga.h" |
| 10 | |
| 11 | |
| 12 | ROM_START( tgui9680 ) |
| 13 | ROM_REGION( 0x8000, "tgui9680", 0 ) |
| 14 | ROM_LOAD16_BYTE( "trident_tgui9680_bios.bin", 0x0000, 0x4000, CRC(1eebde64) SHA1(67896a854d43a575037613b3506aea6dae5d6a19) ) |
| 15 | ROM_CONTINUE( 0x0001, 0x4000 ) |
| 16 | ROM_END |
| 17 | |
| 18 | //************************************************************************** |
| 19 | // GLOBAL VARIABLES |
| 20 | //************************************************************************** |
| 21 | |
| 22 | const device_type ISA8_SVGA_TGUI9680 = &device_creator<isa8_svga_tgui9680_device>; |
| 23 | |
| 24 | |
| 25 | static MACHINE_CONFIG_FRAGMENT( vga_trident ) |
| 26 | MCFG_SCREEN_ADD("screen", RASTER) |
| 27 | MCFG_SCREEN_RAW_PARAMS(XTAL_25_1748MHz,900,0,640,526,0,480) |
| 28 | MCFG_SCREEN_UPDATE_DEVICE("vga", trident_vga_device, screen_update) |
| 29 | |
| 30 | MCFG_PALETTE_ADD("palette", 0x100) |
| 31 | |
| 32 | MCFG_DEVICE_ADD("vga", TRIDENT_VGA, 0) |
| 33 | MACHINE_CONFIG_END |
| 34 | |
| 35 | //------------------------------------------------- |
| 36 | // machine_config_additions - device-specific |
| 37 | // machine configurations |
| 38 | //------------------------------------------------- |
| 39 | |
| 40 | machine_config_constructor isa8_svga_tgui9680_device::device_mconfig_additions() const |
| 41 | { |
| 42 | return MACHINE_CONFIG_NAME( vga_trident ); |
| 43 | } |
| 44 | |
| 45 | //------------------------------------------------- |
| 46 | // rom_region - device-specific ROM region |
| 47 | //------------------------------------------------- |
| 48 | |
| 49 | const rom_entry *isa8_svga_tgui9680_device::device_rom_region() const |
| 50 | { |
| 51 | return ROM_NAME( tgui9680 ); |
| 52 | } |
| 53 | |
| 54 | //************************************************************************** |
| 55 | // LIVE DEVICE |
| 56 | //************************************************************************** |
| 57 | |
| 58 | //------------------------------------------------- |
| 59 | // isa8_vga_device - constructor |
| 60 | //------------------------------------------------- |
| 61 | |
| 62 | isa8_svga_tgui9680_device::isa8_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock) : |
| 63 | device_t(mconfig, ISA8_SVGA_TGUI9680, "Trident TGUI9680 Graphics Card", tag, owner, clock, "tgui9680", __FILE__), |
| 64 | device_isa8_card_interface(mconfig, *this) |
| 65 | { |
| 66 | } |
| 67 | |
| 68 | //------------------------------------------------- |
| 69 | // device_start - device-specific startup |
| 70 | //------------------------------------------------- |
| 71 | READ8_MEMBER(isa8_svga_tgui9680_device::input_port_0_r ) { return 0xff; } //return space.machine().root_device().ioport("IN0")->read(); } |
| 72 | |
| 73 | void isa8_svga_tgui9680_device::device_start() |
| 74 | { |
| 75 | set_isa_device(); |
| 76 | |
| 77 | m_vga = subdevice<trident_vga_device>("vga"); |
| 78 | |
| 79 | m_isa->install_rom(this, 0xc0000, 0xc7fff, 0, 0, "tgui9680", "tgui9680"); |
| 80 | |
| 81 | m_isa->install_device(0x3b0, 0x3bf, 0, 0, read8_delegate(FUNC(trident_vga_device::port_03b0_r),m_vga), write8_delegate(FUNC(trident_vga_device::port_03b0_w),m_vga)); |
| 82 | m_isa->install_device(0x3c0, 0x3cf, 0, 0, read8_delegate(FUNC(trident_vga_device::port_03c0_r),m_vga), write8_delegate(FUNC(trident_vga_device::port_03c0_w),m_vga)); |
| 83 | m_isa->install_device(0x3d0, 0x3df, 0, 0, read8_delegate(FUNC(trident_vga_device::port_03d0_r),m_vga), write8_delegate(FUNC(trident_vga_device::port_03d0_w),m_vga)); |
| 84 | |
| 85 | m_isa->install_memory(0xa0000, 0xbffff, 0, 0, read8_delegate(FUNC(trident_vga_device::mem_r),m_vga), write8_delegate(FUNC(trident_vga_device::mem_w),m_vga)); |
| 86 | } |
| 87 | |
| 88 | //------------------------------------------------- |
| 89 | // device_reset - device-specific reset |
| 90 | //------------------------------------------------- |
| 91 | |
| 92 | void isa8_svga_tgui9680_device::device_reset() |
| 93 | { |
| 94 | } |
trunk/src/emu/bus/isa/svga_trident.h
| r0 | r31939 | |
| 1 | /* |
| 2 | * svga_trident.h |
| 3 | * |
| 4 | * Created on: 6/09/2014 |
| 5 | */ |
| 6 | |
| 7 | #ifndef SVGA_TRIDENT_H_ |
| 8 | #define SVGA_TRIDENT_H_ |
| 9 | |
| 10 | #include "emu.h" |
| 11 | #include "isa.h" |
| 12 | #include "video/pc_vga.h" |
| 13 | |
| 14 | //************************************************************************** |
| 15 | // TYPE DEFINITIONS |
| 16 | //************************************************************************** |
| 17 | |
| 18 | // ======================> isa8_vga_device |
| 19 | |
| 20 | class isa8_svga_tgui9680_device : |
| 21 | public device_t, |
| 22 | public device_isa8_card_interface |
| 23 | { |
| 24 | public: |
| 25 | // construction/destruction |
| 26 | isa8_svga_tgui9680_device(const machine_config &mconfig, const char *tag, device_t *owner, UINT32 clock); |
| 27 | |
| 28 | // optional information overrides |
| 29 | virtual machine_config_constructor device_mconfig_additions() const; |
| 30 | virtual const rom_entry *device_rom_region() const; |
| 31 | |
| 32 | DECLARE_READ8_MEMBER(input_port_0_r); |
| 33 | protected: |
| 34 | // device-level overrides |
| 35 | virtual void device_start(); |
| 36 | virtual void device_reset(); |
| 37 | private: |
| 38 | trident_vga_device *m_vga; |
| 39 | }; |
| 40 | |
| 41 | |
| 42 | // device type definition |
| 43 | extern const device_type ISA8_SVGA_TGUI9680; |
| 44 | |
| 45 | |
| 46 | #endif /* SVGA_TRIDENT_H_ */ |
trunk/src/emu/bus/isa/isa_cards.c
| r31938 | r31939 | |
| 19 | 19 | SLOT_INTERFACE("aga_pc200", ISA8_AGA_PC200) |
| 20 | 20 | SLOT_INTERFACE("ega", ISA8_EGA) |
| 21 | 21 | SLOT_INTERFACE("svga_et4k", ISA8_SVGA_ET4K) |
| 22 | SLOT_INTERFACE("tgui9680",ISA8_SVGA_TGUI9680) |
| 22 | 23 | SLOT_INTERFACE("com", ISA8_COM) |
| 23 | 24 | SLOT_INTERFACE("fdc", ISA8_FDC_SUPERIO) |
| 24 | 25 | SLOT_INTERFACE("fdc_xt", ISA8_FDC_XT) |
| r31938 | r31939 | |
| 57 | 58 | SLOT_INTERFACE("vga", ISA8_VGA) |
| 58 | 59 | SLOT_INTERFACE("svga_et4k", ISA8_SVGA_ET4K) |
| 59 | 60 | SLOT_INTERFACE("svga_dm",ISA8_SVGA_CIRRUS) |
| 61 | SLOT_INTERFACE("tgui9680",ISA8_SVGA_TGUI9680) |
| 60 | 62 | SLOT_INTERFACE("com", ISA8_COM) |
| 61 | 63 | SLOT_INTERFACE("comat", ISA8_COM_AT) |
| 62 | 64 | SLOT_INTERFACE("fdc", ISA8_FDC_AT) |