diff options
author | 2021-04-28 11:12:15 +1000 | |
---|---|---|
committer | 2021-04-28 11:12:15 +1000 | |
commit | 3593491a9013163e0b42cde336f0ec3237e45dbc (patch) | |
tree | 55b43d193ad1033346209b3337cf0e4922a85811 | |
parent | 93d2a3c1c5699af4f0895fc5cd1fc160ca03903c (diff) |
**Added primrag2
-rw-r--r-- | docs/release/docs/hbnew.txt | 1 | ||||
-rw-r--r-- | src/devices/bus/ata/idehd.cpp | 4 | ||||
-rw-r--r-- | src/devices/cpu/psx/irq.cpp | 30 | ||||
-rw-r--r-- | src/hbmame/hbmame.lst | 2 |
4 files changed, 31 insertions, 6 deletions
diff --git a/docs/release/docs/hbnew.txt b/docs/release/docs/hbnew.txt index 89c4375b8f3..e46474d5a47 100644 --- a/docs/release/docs/hbnew.txt +++ b/docs/release/docs/hbnew.txt @@ -7,6 +7,7 @@ New Games --------------------------------- +- [primrag2] Primal Rage 2 - [sailormnbv] Pretty Soldier Sailor Moon (Brutal Version) - [umk3uc20210401] Ultimate Mortal Kombat 3 Ultimate Cup Edition (2021-04-01) - [umk3uc20210423] Ultimate Mortal Kombat 3 Ultimate Cup Edition (2021-04-23) diff --git a/src/devices/bus/ata/idehd.cpp b/src/devices/bus/ata/idehd.cpp index 15a079963de..996324700df 100644 --- a/src/devices/bus/ata/idehd.cpp +++ b/src/devices/bus/ata/idehd.cpp @@ -13,6 +13,7 @@ #define LOGPRINT(x) do { if (VERBOSE) logerror x; if (PRINTF_IDE_COMMANDS) osd_printf_debug x; } while (0) +#define TIME_PER_SECTOR_READ (attotime::from_usec(10)) // MAMEFX #define TIME_PER_SECTOR_WRITE (attotime::from_usec(100)) #define TIME_PER_ROTATION (attotime::from_hz(5400/60)) #define TIME_BETWEEN_SECTORS (attotime::from_nsec(400)) @@ -427,6 +428,9 @@ void ata_mass_storage_device::fill_buffer() if (m_sector_count > 0) { set_dasp(ASSERT_LINE); + if (strcmp("primrag2", machine().system().name) == 0) // MAMEFX + start_busy(TIME_PER_SECTOR_READ, PARAM_COMMAND); // MAMEFX: primrag2 - derived from MAME4RAGE2 emulator + else // MAMEFX if (m_command == IDE_COMMAND_READ_DMA) start_busy(TIME_BETWEEN_SECTORS + m_dma_transfer_time, PARAM_COMMAND); else diff --git a/src/devices/cpu/psx/irq.cpp b/src/devices/cpu/psx/irq.cpp index ace6d69d4e6..51385487500 100644 --- a/src/devices/cpu/psx/irq.cpp +++ b/src/devices/cpu/psx/irq.cpp @@ -66,16 +66,34 @@ void psxirq_device::set( uint32_t bitmask ) void psxirq_device::psx_irq_update( void ) { - if( ( n_irqdata & n_irqmask ) != 0 ) + // MAMEFX start + if (strcmp("primrag2", machine().system().name) != 0) { - verboselog( *this, 2, "psx irq assert\n" ); - m_irq_handler( ASSERT_LINE ); + if( ( n_irqdata & n_irqmask ) != 0 ) + m_irq_handler( ASSERT_LINE ); + else + m_irq_handler( CLEAR_LINE ); } else { - verboselog( *this, 2, "psx irq clear\n" ); - m_irq_handler( CLEAR_LINE ); - } + +// primrag2 only - this code derived from MAME4RAGE2 emulator + if( ( n_irqmask == 0x9 ) && ( n_irqdata == 0x1 ) ) + m_irq_handler (ASSERT_LINE); + else + if( ( n_irqmask == 0x449 ) && + ( (n_irqdata == 1) || (n_irqdata == 9) || (n_irqdata == 0x40) || (n_irqdata == 0x48) || (n_irqdata == 0x49) + || (n_irqdata == 0x401) || (n_irqdata == 0x409) || (n_irqdata == 0x441) || (n_irqdata == 0x448) ) ) + m_irq_handler (ASSERT_LINE); + else + if( ( n_irqmask == 0x649 ) && + ( (n_irqdata == 1) || (n_irqdata == 0x41) || (n_irqdata == 0x201) || (n_irqdata == 0x241) + || (n_irqdata == 0x401) || (n_irqdata == 0x441) || (n_irqdata == 0x601) || (n_irqdata == 0x641) ) ) + m_irq_handler (ASSERT_LINE); + else + m_irq_handler (CLEAR_LINE); + } + // MAMEFX end } void psxirq_device::write(offs_t offset, uint32_t data, uint32_t mem_mask) diff --git a/src/hbmame/hbmame.lst b/src/hbmame/hbmame.lst index 4413b0b3a61..c9b94af6294 100644 --- a/src/hbmame/hbmame.lst +++ b/src/hbmame/hbmame.lst @@ -8968,10 +8968,12 @@ zex8085 @source:zn.cpp coh1000c coh1002m +coh1000w coh3002c doapp //parent doapph01 doappnud +primrag2 sfex //parent sfexs01 sfex2 //parent |