~ubuntu-branches/ubuntu/edgy/vice/edgy

« back to all changes in this revision

Viewing changes to src/c64/c64.c

  • Committer: Bazaar Package Importer
  • Author(s): Zed Pobre
  • Date: 2006-07-30 19:15:59 UTC
  • mfrom: (1.1.3 upstream)
  • Revision ID: james.westby@ubuntu.com-20060730191559-aybuaxdqc7uc57fc
Tags: 1.19-1
* New upstream version (Closes: #344245, #379781)
* Reference to roms in package description fixed (Closes: #302900)
* Acknowledge xlibs NMU (Closes: #346768)
* Build-Depends: bison++ | bison
* Build-Depends: libxaw-headers

Show diffs side-by-side

added added

removed removed

Lines of Context:
37
37
#include "c64-resources.h"
38
38
#include "c64-snapshot.h"
39
39
#include "c64.h"
 
40
#include "c64_256k.h"
40
41
#include "c64acia.h"
41
42
#include "c64cart.h"
42
43
#include "c64cia.h"
57
58
#include "drive-resources.h"
58
59
#include "drive.h"
59
60
#include "drivecpu.h"
 
61
#include "georam.h"
60
62
#include "imagecontents.h"
61
63
#include "kbdbuf.h"
62
64
#include "keyboard.h"
68
70
#include "maincpu.h"
69
71
#include "mem.h"
70
72
#include "monitor.h"
 
73
#include "network.h"
71
74
#include "parallel.h"
72
75
#include "patchrom.h"
 
76
#include "plus60k.h"
73
77
#include "printer.h"
74
78
#include "psid.h"
 
79
#include "ramcart.h"
75
80
#include "resources.h"
76
81
#include "reu.h"
77
82
#include "rs232drv.h"
241
246
        || c64_resources_init() < 0
242
247
        || c64export_resources_init() < 0
243
248
        || reu_resources_init() < 0
 
249
        || georam_resources_init() < 0
 
250
        || ramcart_resources_init() < 0
 
251
        || plus60k_resources_init() < 0
 
252
        || c64_256k_resources_init() < 0
244
253
#ifdef HAVE_TFE
245
254
        || tfe_resources_init() < 0
246
255
#endif
247
 
        || vicii_resources_init() < 0
 
256
        || vicii_resources_init() < 0
248
257
        || sound_resources_init() < 0
249
258
        || sid_resources_init() < 0
250
259
        || acia1_resources_init() < 0
276
285
    video_resources_shutdown();
277
286
    c64_resources_shutdown();
278
287
    reu_resources_shutdown();
 
288
    georam_resources_shutdown();
 
289
    ramcart_resources_shutdown();
 
290
    plus60k_resources_shutdown();
 
291
    c64_256k_resources_shutdown();
279
292
    sound_resources_shutdown();
280
293
    rs232drv_resources_shutdown();
281
294
    printer_resources_shutdown();
301
314
        || video_init_cmdline_options() < 0
302
315
        || c64_cmdline_options_init() < 0
303
316
        || reu_cmdline_options_init() < 0
 
317
        || georam_cmdline_options_init() < 0
 
318
        || ramcart_cmdline_options_init() < 0
 
319
        || plus60k_cmdline_options_init() < 0
 
320
        || c64_256k_cmdline_options_init() < 0
304
321
#ifdef HAVE_TFE
305
322
        || tfe_cmdline_options_init() < 0
306
323
#endif
331
348
{
332
349
    unsigned int dnr;
333
350
    monitor_cpu_type_t asm6502;
 
351
    monitor_interface_t *drive_interface_init[DRIVE_NUM];
 
352
 
 
353
#ifdef MINIXVMD
 
354
    monitor_cpu_type_t *asmarray[2];
 
355
    asmarray[0]=&asm6502;
 
356
    asmarray[1]=NULL;
 
357
#else
334
358
    monitor_cpu_type_t *asmarray[2] = { &asm6502, NULL };
335
 
    monitor_interface_t *drive_interface_init[DRIVE_NUM];
 
359
#endif
336
360
 
337
361
    asm6502_init(&asm6502);
338
362
 
449
473
        /* Initialize the REU.  */
450
474
        reu_init();
451
475
 
 
476
        /* Initialize the GEORAM.  */
 
477
        georam_init();
 
478
 
 
479
        /* Initialize the RAMCART.  */
 
480
        ramcart_init();
 
481
 
 
482
        /* Initialize the +60K.  */
 
483
        plus60k_init();
 
484
 
 
485
        /* Initialize the 256K.  */
 
486
        c64_256k_init();
 
487
 
452
488
#ifdef HAVE_TFE
453
489
        /* Initialize the TFE.  */
454
490
        tfe_init();
504
540
    drive_reset();
505
541
    datasette_reset();
506
542
    reu_reset();
 
543
    georam_reset();
 
544
    ramcart_reset();
 
545
    plus60k_reset();
 
546
    c64_256k_reset();
507
547
}
508
548
 
509
549
void machine_specific_powerup(void)
532
572
    vicii_shutdown();
533
573
 
534
574
    reu_shutdown();
 
575
    georam_shutdown();
 
576
    ramcart_shutdown();
 
577
    plus60k_shutdown();
 
578
    c64_256k_shutdown();
535
579
 
536
580
#ifdef HAVE_TFE
537
581
    /* Shutdown the TFE.  */
571
615
        return;
572
616
    }
573
617
 
 
618
    network_hook();
 
619
 
574
620
    drive_vsync_hook();
575
621
 
576
622
    autostart_advance();
584
630
    drivecpu_prevent_clk_overflow_all(sub);
585
631
}
586
632
 
587
 
int machine_set_restore_key(int v)
 
633
void machine_set_restore_key(int v)
588
634
{
589
635
    c64keyboard_restore_key(v);
 
636
}
 
637
 
 
638
int machine_has_restore_key(void)
 
639
{
590
640
    return 1;
591
641
}
592
642