1.1 diff -r e5a92d7beecf -r a350dfa92895 src/main.c 1.2 --- a/src/main.c Sun Dec 05 16:18:50 2010 +0000 1.3 +++ b/src/main.c Sun Dec 05 16:20:00 2010 +0000 1.4 @@ -188,6 +188,10 @@ 1.5 printf("Set %dx%d at %d bits-per-pixel mode\n\n", screen->w, screen->h, screen->format->BitsPerPixel); 1.6 SDL_WM_SetCaption("FreeBee 3B1 emulator", "FreeBee"); 1.7 1.8 + // Load a disc image 1.9 + FILE *disc = fopen("discim", "rb"); 1.10 + wd2797_load(&state.fdc_ctx, disc, 512, 10, 2); 1.11 + 1.12 /*** 1.13 * The 3B1 CPU runs at 10MHz, with DMA running at 1MHz and video refreshing at 1.14 * around 60Hz (???), with a 60Hz periodic interrupt. 1.15 @@ -237,5 +241,9 @@ 1.16 if (exitEmu) break; 1.17 } 1.18 1.19 + // Release the disc image 1.20 + wd2797_unload(&state.fdc_ctx); 1.21 + fclose(disc); 1.22 + 1.23 return 0; 1.24 }