~ubuntu-branches/debian/sid/mame/sid

« back to all changes in this revision

Viewing changes to src/mame/machine/theglobp.c

  • Committer: Package Import Robot
  • Author(s): Jordi Mallach, Emmanuel Kasper, Jordi Mallach
  • Date: 2012-06-05 20:02:23 UTC
  • mfrom: (0.3.1) (0.1.4)
  • Revision ID: package-import@ubuntu.com-20120605200223-gnlpogjrg6oqe9md
Tags: 0.146-1
[ Emmanuel Kasper ]
* New upstream release
* Drop patch to fix man pages section and patches to link with flac 
  and jpeg system lib: all this has been pushed upstream by Cesare Falco
* Add DM-Upload-Allowed: yes field.

[ Jordi Mallach ]
* Create a "gnu" TARGETOS stanza that defines NO_AFFINITY_NP.
* Stop setting TARGETOS to "unix" in d/rules. It should be autodetected,
  and set to the appropriate value.
* mame_manpage_section.patch: Change mame's manpage section to 6 (games),
  in the TH declaration.

Show diffs side-by-side

added added

removed removed

Lines of Context:
71
71
        int mem;
72
72
        UINT8 *RAM;
73
73
 
74
 
        RAM = machine.region("maincpu")->base();
 
74
        RAM = machine.root_device().memregion("maincpu")->base();
75
75
 
76
76
 
77
77
        for (mem=0;mem<0x4000;mem++)
108
108
        int mem;
109
109
        UINT8 *RAM;
110
110
 
111
 
        RAM = machine.region("maincpu")->base();
 
111
        RAM = machine.root_device().memregion("maincpu")->base();
112
112
 
113
113
        for (mem=0;mem<0x4000;mem++)
114
114
        {
143
143
        int mem;
144
144
        UINT8 *RAM;
145
145
 
146
 
        RAM = machine.region("maincpu")->base();
 
146
        RAM = machine.root_device().memregion("maincpu")->base();
147
147
 
148
148
        for (mem=0;mem<0x4000;mem++)
149
149
        {
178
178
        int mem;
179
179
        UINT8 *RAM;
180
180
 
181
 
        RAM = machine.region("maincpu")->base();
 
181
        RAM = machine.root_device().memregion("maincpu")->base();
182
182
 
183
183
        for (mem=0;mem<0x4000;mem++)
184
184
        {
222
222
 
223
223
        switch(state->m_counter)
224
224
        {
225
 
                case 0x08:      memory_set_bank (space->machine(), "bank1", 0);         break;
226
 
                case 0x09:      memory_set_bank (space->machine(), "bank1", 1);         break;
227
 
                case 0x0A:      memory_set_bank (space->machine(), "bank1", 2);         break;
228
 
                case 0x0B:      memory_set_bank (space->machine(), "bank1", 3);         break;
 
225
                case 0x08:      state->membank ("bank1")->set_entry (0);                break;
 
226
                case 0x09:      state->membank ("bank1")->set_entry (1);                break;
 
227
                case 0x0A:      state->membank ("bank1")->set_entry (2);                break;
 
228
                case 0x0B:      state->membank ("bank1")->set_entry (3);                break;
229
229
                default:
230
230
                        logerror("Invalid counter = %02X\n",state->m_counter);
231
231
                        break;
238
238
MACHINE_START( theglobp )
239
239
{
240
240
        pacman_state *state = machine.driver_data<pacman_state>();
241
 
        UINT8 *RAM = machine.region("maincpu")->base();
 
241
        UINT8 *RAM = state->memregion("maincpu")->base();
242
242
 
243
243
        /* While the PAL supports up to 16 decryption methods, only four
244
244
        are actually used in the PAL.  Therefore, we'll take a little
248
248
        theglobp_decrypt_rom_A(machine);
249
249
        theglobp_decrypt_rom_B(machine);
250
250
 
251
 
        memory_configure_bank(machine, "bank1", 0, 4, &RAM[0x10000], 0x4000);
 
251
        state->membank("bank1")->configure_entries(0, 4, &RAM[0x10000], 0x4000);
252
252
 
253
253
        state_save_register_global(machine, state->m_counter);
254
254
}
259
259
        pacman_state *state = machine.driver_data<pacman_state>();
260
260
        /* The initial state of the counter is 0x0A */
261
261
        state->m_counter = 0x0A;
262
 
        memory_set_bank(machine, "bank1", 2);
 
262
        state->membank("bank1")->set_entry(2);
263
263
}