summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--src/mame/drivers/jokrwild.c139
1 files changed, 55 insertions, 84 deletions
diff --git a/src/mame/drivers/jokrwild.c b/src/mame/drivers/jokrwild.c
index 879d1cac407..c4b041c4c46 100644
--- a/src/mame/drivers/jokrwild.c
+++ b/src/mame/drivers/jokrwild.c
@@ -2,94 +2,75 @@
// copyright-holders:Roberto Fresca
/******************************************************************************
- JOKER'S WILD - SIGMA
- --------------------
-
- Preliminary driver by Roberto Fresca.
-
-
- Games running on this hardware:
-
- * Joker's Wild (encrypted). 1988, Sigma.
+ JOKER'S WILD - SIGMA (1988)
+ Preliminary driver by Roberto Fresca.
*******************************************************************************
+ Hardware Notes (guessed):
+ ------------------------
- Hardware Notes (guessed):
- ------------------------
-
- CPU: 1x M6809
- Video: 1x M6845 CRTC or similar.
- I/O: 2x PIAs ?? (there is code to initialize PIAs at $8033)
-
+ CPU: 1x M6809
+ Video: 1x M6845 CRTC or similar.
+ I/O: 2x PIAs ?? (there is code to initialize PIAs at $8033)
*******************************************************************************
+ *** Game Notes ***
- *** Game Notes ***
-
- Game is trying to boot, and after approx. 90 seconds an error message appear
- on screen: "Random number generator is defective", then stuck here.
-
- See code at $9859
-
- PIAs are commented out just to see the R/W on error log.
+ RND old notes:
+ Game is trying to boot, and after approx. 90 seconds an error message appear
+ on screen: "Random number generator is defective", then stuck here.
+ See code at $9859
+ Currently the game spit an error about bad RAM, and after approx 90 seconds
+ the playfield is drawn and then hang.
*******************************************************************************
- --------------------
- *** Memory Map ***
- --------------------
+ --------------------
+ *** Memory Map ***
+ --------------------
- 0x0000 - 0x07FF ; Video RAM.
- 0x2000 - 0x27FF ; Color RAM.
- 0x4004 - 0x4007 ; PIA?.
- 0x4008 - 0x400B ; PIA?.
- 0x6000 - 0x6001 ; M6845 CRTC.
- 0x8000 - 0xFFFF ; ROM space.
+ 0x0000 - 0x07FF ; Video RAM.
+ 0x2000 - 0x27FF ; Color RAM.
+ 0x4004 - 0x4007 ; PIA?.
+ 0x4008 - 0x400B ; PIA?.
+ 0x6000 - 0x6001 ; M6845 CRTC.
+ 0x8000 - 0xFFFF ; ROM space.
- *** MC6545 Initialization ***
- ----------------------------------------------------------------------------------------------------------------------
- register: R00 R01 R02 R03 R04 R05 R06 R07 R08 R09 R10 R11 R12 R13 R14 R15 R16 R17
- ----------------------------------------------------------------------------------------------------------------------
- value: 0x20 0x18 0x1B 0x64 0x20 0x07 0x1A 0x1D 0x00 0x07 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00.
-
+ *** MC6545 Initialization ***
+ ----------------------------------------------------------------------------------------------------------------------
+ register: R00 R01 R02 R03 R04 R05 R06 R07 R08 R09 R10 R11 R12 R13 R14 R15 R16 R17
+ ----------------------------------------------------------------------------------------------------------------------
+ value: 0x20 0x18 0x1B 0x64 0x20 0x07 0x1A 0x1D 0x00 0x07 0x00 0x00 0x00 0x00 0x00 0x00 0x00 0x00.
*******************************************************************************
+ DRIVER UPDATES:
- DRIVER UPDATES:
-
-
- [2008-10-30]
-
- - Fixed graphics to 2 bits per pixel.
-
-
- [2008-10-25]
-
- - Initial release.
- - ROMs load OK.
- - Proper ROMs decryption.
- - Added MC6845 CRTC.
- - Video RAM OK.
- - Added technical notes.
-
+ [2008-10-30]
+ - Fixed graphics to 2 bits per pixel.
- TODO:
+ [2008-10-25]
+ - Initial release.
+ - ROMs load OK.
+ - Proper ROMs decryption.
+ - Added MC6845 CRTC.
+ - Video RAM OK.
+ - Added technical notes.
- - RND number generator.
- - Inputs
- - Sound.
- - A lot of work.
+ TODO:
+ - RND number generator.
+ - Inputs
+ - Sound.
+ - A lot of work.
*******************************************************************************/
-
#define MASTER_CLOCK XTAL_8MHz /* guess */
#include "emu.h"
@@ -131,21 +112,18 @@ public:
* Video Hardware *
*************************/
-
WRITE8_MEMBER(jokrwild_state::jokrwild_videoram_w)
{
m_videoram[offset] = data;
m_bg_tilemap->mark_tile_dirty(offset);
}
-
WRITE8_MEMBER(jokrwild_state::jokrwild_colorram_w)
{
m_colorram[offset] = data;
m_bg_tilemap->mark_tile_dirty(offset);
}
-
TILE_GET_INFO_MEMBER(jokrwild_state::get_bg_tile_info)
{
/* - bits -
@@ -160,31 +138,23 @@ TILE_GET_INFO_MEMBER(jokrwild_state::get_bg_tile_info)
SET_TILE_INFO_MEMBER(0, code , color , 0);
}
-
void jokrwild_state::video_start()
{
m_bg_tilemap = &machine().tilemap().create(m_gfxdecode, tilemap_get_info_delegate(FUNC(jokrwild_state::get_bg_tile_info),this), TILEMAP_SCAN_ROWS, 8, 8, 24, 26);
}
-
UINT32 jokrwild_state::screen_update_jokrwild(screen_device &screen, bitmap_ind16 &bitmap, const rectangle &cliprect)
{
m_bg_tilemap->draw(screen, bitmap, cliprect, 0, 0);
return 0;
}
-
PALETTE_INIT_MEMBER(jokrwild_state, jokrwild)
{
//missing proms
}
-/*************************
-* Machine Init *
-*************************/
-
-
/*****************************
* Read/Write Handlers *
*****************************/
@@ -200,6 +170,7 @@ READ8_MEMBER(jokrwild_state::rng_r)
return machine().rand() & 0xff;
}
+
/*************************
* Memory Map Information *
*************************/
@@ -220,7 +191,6 @@ static ADDRESS_MAP_START( jokrwild_map, AS_PROGRAM, 8, jokrwild_state )
AM_RANGE(0x8000, 0xffff) AM_ROM
ADDRESS_MAP_END
-
/* I/O byte R/W
@@ -238,6 +208,7 @@ ADDRESS_MAP_END
*/
+
/*************************
* Input Ports *
*************************/
@@ -425,6 +396,7 @@ WRITE8_MEMBER(jokrwild_state::testb_w)
// printf("%02x B\n",data);
}
+
/*************************
* Machine Drivers *
*************************/
@@ -452,8 +424,8 @@ static MACHINE_CONFIG_START( jokrwild, jokrwild_state )
MCFG_SCREEN_ADD("screen", RASTER)
MCFG_SCREEN_REFRESH_RATE(60)
MCFG_SCREEN_VBLANK_TIME(ATTOSECONDS_IN_USEC(0))
- MCFG_SCREEN_SIZE((32+1)*8, (32+1)*8) /* From MC6845, registers 00 & 04. (value-1) */
- MCFG_SCREEN_VISIBLE_AREA(0*8, 24*8-1, 0*8, 26*8-1) /* From MC6845, registers 01 & 06 */
+ MCFG_SCREEN_SIZE((32+1)*8, (32+1)*8) // From MC6845, registers 00 & 04. (value-1)
+ MCFG_SCREEN_VISIBLE_AREA(0*8, 24*8-1, 0*8, 26*8-1) // From MC6845, registers 01 & 06.
MCFG_SCREEN_UPDATE_DRIVER(jokrwild_state, screen_update_jokrwild)
MCFG_SCREEN_PALETTE("palette")
@@ -504,17 +476,16 @@ ROM_END
DRIVER_INIT_MEMBER(jokrwild_state,jokrwild)
/*****************************************************************************
- Encryption was made by pages of 256 bytes.
-
- For each page, the value is XORed with a fixed value (0xCC),
- then XORed again with the offset of the original value inside its own page.
+ Encryption was made by pages of 256 bytes.
- Example:
+ For each page, the value is XORed with a fixed value (0xCC),
+ then XORed again with the offset of the original value inside its own page.
- For encrypted value at offset 0x123A (0x89)...
+ Example:
- 0x89 XOR 0xCC XOR 0x3A = 0x7F
+ For encrypted value at offset 0x123A (0x89)...
+ 0x89 XOR 0xCC XOR 0x3A = 0x7F
*****************************************************************************/
{
@@ -533,5 +504,5 @@ DRIVER_INIT_MEMBER(jokrwild_state,jokrwild)
* Game Drivers *
*************************/
-/* YEAR NAME PARENT MACHINE INPUT INIT ROT COMPANY FULLNAME FLAGS */
+/* YEAR NAME PARENT MACHINE INPUT STATE INIT ROT COMPANY FULLNAME FLAGS */
GAME( 1988, jokrwild, 0, jokrwild, jokrwild, jokrwild_state, jokrwild, ROT0, "Sigma", "Joker's Wild (encrypted)", GAME_NO_SOUND | GAME_NOT_WORKING )