2021-12-17 15:42:22 +00:00
|
|
|
#include <tms9918.h>
|
2021-12-03 10:15:25 +00:00
|
|
|
|
2021-12-15 13:38:52 +00:00
|
|
|
#include "demo_screen1.h"
|
|
|
|
#include "demo_screen2.h"
|
2021-12-23 17:55:56 +00:00
|
|
|
#include "demo_balloon.h"
|
2021-12-15 13:38:52 +00:00
|
|
|
#include "demo_amiga_hand.h"
|
|
|
|
#include "demo_interrupt.h"
|
|
|
|
#include "demo_extvid.h"
|
|
|
|
#include "demo_blank.h"
|
2021-12-17 09:23:18 +00:00
|
|
|
#include "demo_end_of_frame.h"
|
2021-12-08 11:53:13 +00:00
|
|
|
|
|
|
|
void help() {
|
|
|
|
woz_puts(
|
|
|
|
"\rTMS9918 DEMOS\r"
|
|
|
|
"=============\r"
|
|
|
|
"1 SCREEN1\r"
|
|
|
|
"2 SCREEN2\r"
|
2021-12-23 17:55:56 +00:00
|
|
|
"3 BALLOON\r"
|
2021-12-08 11:53:13 +00:00
|
|
|
"A AMIGA HAND\r"
|
|
|
|
"I INTERRUPT\r"
|
|
|
|
"E FLIP EXT VIDEO\r"
|
2021-12-17 09:23:18 +00:00
|
|
|
"F TEST END-OF-FRAME\r"
|
2021-12-08 11:53:13 +00:00
|
|
|
"B BLANK ON/OFF\r"
|
|
|
|
"H HELP\r"
|
|
|
|
"0 EXITS\r\r"
|
|
|
|
);
|
2021-12-05 15:22:27 +00:00
|
|
|
}
|
|
|
|
|
2021-11-28 14:05:41 +00:00
|
|
|
void main() {
|
2021-12-15 17:16:31 +00:00
|
|
|
|
2022-01-01 10:18:19 +00:00
|
|
|
#ifdef APPLE1_JUKEBOX
|
2021-12-15 17:16:31 +00:00
|
|
|
apple1_eprom_init();
|
|
|
|
#endif
|
|
|
|
|
2021-12-08 11:53:13 +00:00
|
|
|
byte key = 'H';
|
2021-11-28 14:05:41 +00:00
|
|
|
for(;;) {
|
2021-12-16 17:33:56 +00:00
|
|
|
if(key == '1') demo_screen1();
|
|
|
|
else if(key == '2') demo_screen2();
|
2021-12-23 17:55:56 +00:00
|
|
|
else if(key == '3') demo_balloon();
|
2021-12-08 11:53:13 +00:00
|
|
|
else if(key == 'A') demo_amiga_hand();
|
|
|
|
else if(key == 'I') demo_interrupt();
|
|
|
|
else if(key == 'E') flip_external_input();
|
2021-12-17 09:23:18 +00:00
|
|
|
else if(key == 'F') demo_end_of_frame();
|
2021-12-08 11:53:13 +00:00
|
|
|
else if(key == 'B') flip_blank();
|
|
|
|
else if(key == 'H') help();
|
2021-11-28 15:43:33 +00:00
|
|
|
else if(key == '0') break;
|
2021-11-28 14:05:41 +00:00
|
|
|
else woz_putc(key);
|
2021-11-26 22:41:51 +00:00
|
|
|
|
2021-12-15 13:38:52 +00:00
|
|
|
key = apple1_getkey();
|
2021-11-28 14:05:41 +00:00
|
|
|
}
|
2021-12-08 11:53:13 +00:00
|
|
|
woz_puts("BYE\r");
|
2021-11-26 22:41:51 +00:00
|
|
|
woz_mon();
|
|
|
|
}
|