Previous 15994 Revisions Next

r4400 Friday 6th March, 2009 at 14:35:20 UTC by Robbbert
[ATOM] Fixed boot problem.
[src/mess/drivers]atom.c
[src/mess/machine]atom.c

src/mess/machine/atom.c
r4399r4400
174174   }
175175}
176176
177
178static DIRECT_UPDATE_HANDLER(atom_opbase_handler)
179{
180   /* clear op base override */
181   memory_set_direct_update_handler(space, NULL);
182
183   /* this is temporary */
184   /* Kees van Oss mentions that address 8-b are used for the random number
185   generator. I don't know if this is hardware, or random data because the
186   ram chips are not cleared at start-up. So at this time, these numbers
187   are poked into the memory to simulate it. When I have more details I will fix it */
188   memory_region(space->machine, "maincpu")[0x08] = mame_rand(space->machine) & 0x0ff;
189   memory_region(space->machine, "maincpu")[0x09] = mame_rand(space->machine) & 0x0ff;
190   memory_region(space->machine, "maincpu")[0x0a] = mame_rand(space->machine) & 0x0ff;
191   memory_region(space->machine, "maincpu")[0x0b] = mame_rand(space->machine) & 0x0ff;
192
193   return cpu_get_pc( space->cpu ) & 0x0ffff;
194}
195
196177MACHINE_RESET( atom )
197178{
198179   atom_8255_porta = 0xff;
r4399r4400
202183   timer_state = 0;
203184   timer_pulse(machine, ATTOTIME_IN_HZ(2400*2), NULL, 0, atom_timer_callback);
204185
205   memory_set_direct_update_handler(cpu_get_address_space( machine->cpu[0], ADDRESS_SPACE_PROGRAM ),atom_opbase_handler);
186   /* this is temporary */
187   /* Kees van Oss mentions that address 8-b are used for the random number
188   generator. I don't know if this is hardware, or random data because the
189   ram chips are not cleared at start-up. So at this time, these numbers
190   are poked into the memory to simulate it. When I have more details I will fix it */
191   memory_region(machine, "maincpu")[0x08] = mame_rand(machine) & 0x0ff;
192   memory_region(machine, "maincpu")[0x09] = mame_rand(machine) & 0x0ff;
193   memory_region(machine, "maincpu")[0x0a] = mame_rand(machine) & 0x0ff;
194   memory_region(machine, "maincpu")[0x0b] = mame_rand(machine) & 0x0ff;
206195}
207196
208197struct atm
src/mess/drivers/atom.c
r4399r4400
358358SYSTEM_CONFIG_END
359359
360360/*    YEAR  NAME      PARENT    COMPAT  MACHINE   INPUT     INIT      CONFIG   COMPANY   FULLNAME */
361COMP( 1979, atom,     0,        0,      atom,     atom,     0,        atom,    "Acorn",  "Atom" , GAME_NOT_WORKING)
362COMP( 1979, atomeb,   atom,     0,      atomeb,   atom,     0,        atom,    "Acorn",  "Atom with Eprom Box" , GAME_NOT_WORKING)
361COMP( 1979, atom,     0,        0,      atom,     atom,     0,        atom,    "Acorn",  "Atom" , 0)
362COMP( 1979, atomeb,   atom,     0,      atomeb,   atom,     0,        atom,    "Acorn",  "Atom with Eprom Box" , 0)

Previous 15994 Revisions Next


© 1998-2018 The MESS Team