Previous 15994 Revisions Next

r9872 Saturday 1st January, 2011 at 13:12:39 UTC by Wilbert Pol
[OSBEXEC] More banking fixes.
[src/mess/drivers]osbexec.c

src/mess/drivers/osbexec.c
r9871r9872
22
33    Osborne Executive driver file
44
5Screen is 80x24
6
7On boot at least bios seems to be enabled.
8
9Floppy breakpoints:
10- bp 0c50
11- bp 1449
12- bp 1465
13
14
155***************************************************************************/
166
177#include "emu.h"
r9871r9872
7363
7464   void set_banks(running_machine *machine)
7565   {
76      ram_0000 = messram_get_ptr( messram );
66      UINT8 *messram_ptr = messram_get_ptr( messram );
7767
68      ram_0000 = messram_ptr;
69
7870      if ( pia0_porta & 0x01 )
7971         ram_0000 += 0x10000;
8072
8173      memory_set_bankptr( machine, "0000", ram_0000 + 0x0000 );
74      memory_set_bankptr( machine, "2000", ram_0000 + 0x2000 );
8275      memory_set_bankptr( machine, "4000", ram_0000 + 0x4000 );
8376      memory_set_bankptr( machine, "c000", ram_0000 + 0xc000 );
8477      memory_set_bankptr( machine, "e000", ram_0000 + 0xe000 );
8578
8679      if ( pia0_porta & 0x80 )
80      {
8781         memory_set_bankptr( machine, "0000", memory_region(machine, "maincpu") );
82         /* When BIOS is enabled 2000-3FFF (or maybe 2000-2FFF) is taken from the first 64KB ) */
83         memory_set_bankptr( machine, "2000", messram_ptr + 0x2000 );
84      }
8885
8986      if ( pia0_porta & 0x40 )
9087         memory_set_bankptr(machine, "c000", vram_region->base() );
r9871r9872
159156
160157static ADDRESS_MAP_START( osbexec_mem, ADDRESS_SPACE_PROGRAM, 8 )
161158   AM_RANGE( 0x0000, 0x1FFF ) AM_READ_BANK("0000") AM_WRITE( osbexec_0000_w )   /* ROM and maybe also banked ram */
162   AM_RANGE( 0x2000, 0x3FFF ) AM_RAM                                 /* Banked? RAM */
163   AM_RANGE( 0x4000, 0xBFFF ) AM_RAMBANK("4000")                        /* Banked ram */
159   AM_RANGE( 0x2000, 0x3FFF ) AM_RAMBANK("2000")                        /* Banked RAM */
160   AM_RANGE( 0x4000, 0xBFFF ) AM_RAMBANK("4000")                        /* Banked RAM */
164161   AM_RANGE( 0xC000, 0xDFFF ) AM_RAMBANK("c000")                        /* Video ram / Banked RAM */
165   AM_RANGE( 0xE000, 0xEFFF ) AM_RAMBANK("e000")                        /* Banked ram */
162   AM_RANGE( 0xE000, 0xEFFF ) AM_RAMBANK("e000")                        /* Banked RAM */
166163   AM_RANGE( 0xF000, 0xFFFF ) AM_RAM                                 /* 4KB of non-banked RAM for system stack etc */
167164ADDRESS_MAP_END
168165

Previous 15994 Revisions Next


© 1998-2018 The MESS Team