25개 이상의 토픽을 선택하실 수 없습니다. Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
921B

  1. /* {{PROJECT_NAME}} - starter program generated by the C64/C128 Dev Foundry.
  2. ** Mixed C + ca65: frame.s provides wait_frame(), a raster-synchronised frame wait.
  3. ** Milestone M0 only: proves the toolchain, the display, the frame loop and the smoke test.
  4. */
  5. #include <conio.h>
  6. #if defined(__C128__)
  7. #include <c128.h>
  8. #endif
  9. #include "smoke.h"
  10. #include "frame.h"
  11. int main(void)
  12. {
  13. unsigned char frames = 0;
  14. #if defined(__C128__) && defined(FOUNDRY_VDC80)
  15. videomode(VIDEOMODE_80COL);
  16. #elif defined(__C128__)
  17. videomode(VIDEOMODE_40COL);
  18. #endif
  19. clrscr();
  20. cputsxy(0, 0, "{{SCREEN_TITLE}}");
  21. cputsxy(0, 2, "STARTER OK");
  22. cputsxy(0, 4, "PRESS ANY KEY TO RETURN TO BASIC");
  23. cputsxy(0, 6, "FRAME:");
  24. smoke_capture();
  25. smoke_ready();
  26. while (!kbhit()) {
  27. wait_frame();
  28. gotoxy(7, 6);
  29. cprintf("%3u", (unsigned)frames++);
  30. }
  31. cgetc();
  32. clrscr();
  33. return 0;
  34. }

Powered by TurnKey Linux.