Jump to content

Greg King

Members
  • Content Count

    116
  • Joined

  • Last visited

  • Days Won

    3

Greg King last won the day on August 19 2020

Greg King had the most liked content!

Community Reputation

65 Excellent

1 Follower

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Those constants are for cc65's joystick driver. The Commander version uses the KERNAL function joystick_get. The driver knows the difference between NES and SNES. The "standard" driver always uses buttons A and B as fire buttons 1 and 2. If someone feels that other buttons are more convenient as the fire buttons, then more joystick drivers can be added to the library.
  2. However, I couldn't resist the urge to do what @AndyMt has done. So, I made a feature branch, and updated its cc65 project files for R39. https://github.com/greg-king5/cc65/tree/commander-r39
  3. Don't bother with a PR. We won't update until R39 is released officially.
  4. If you want to see the native stuff that we had back in the good old days, then look at https://www.lyonlabs.org/commodore/onrequest/collections.html and https://telarity.com/~dan/cbm/languages.html
  5. Yep! We want waitvsync() to stop waiting, after a VSYNC, as soon as it's conveniently possible. The ideal method would "plug" into the interrupt vector, but that way is more complex. And, it might interfere with other interrupt handlers. I chose to make the function small and benign.
  6. VLOAD is documented in a pull request. I'm surprised that Michael hasn't merged it yet. https://github.com/commanderx16/x16-docs/pull/46/files
  7. SAVE does that, too. The difference between them is that DSAVE can supply a device number (the most recently used one) and a drive number for you.
  8. BASIC doesn't care about the second address; it merely passes that address to Kernal. When you use the LOAD command -- at the "READY." prompt -- BASIC always does two things: Sets its end-of-program pointer to the value returned by Kernal. Tries to relink the line pointers, starting at the beginning of BASIC RAM. Those actions can cause trouble. For example, if you type in a program, then LOAD the VTUI library into "Golden RAM", then RUN your program, it will fail! BASIC will put the program's variables at addresses immediately above VTUI instead of above the program. (You must edit your program, again, so that BASIC will set that pointer back to the end of your program.)
  9. Yes. cbm_k_bsout(RVS_ON);works with stdio functions, such as puts() and printf(). revers(1)works with conio functions, such as cputs() and cprintf().
  10. Yep. LOAD and SAVE are the only things that you can do on the host's file-system. If you really want to avoid those extra bytes, then you must work with an SD card image. You had the right idea with cbm_read(). Here's some example code: #include <stdint.h> #include <stdio.h> #include <peekpoke.h> #include <cbm.h> #include <errno.h> uint8_t readbin2bank(char name[], uint8_t bank) { uint8_t err; int len; POKE(REG_RAMBANK, bank); err = cbm_open(2, 8, 2, name); if (err != 0) { return err; } len = cbm_read(2, 0xA000, 0x2000); // Read as much as allowed into current RAM bank. if (len < 0) { cbm_close(2); return _oserror; } printf("Read %d bytes into RAM bank %u.\n", len, bank); cbm_close(2); return 0; }
  11. The POKE() isn't needed. You're replacing the firmware's font. Therefore, that location already has 0x7C.
  12. A pull request already was posted for it: https://github.com/commanderx16/x16-rom/pull/173
  13. I know -- 0.6 version. Those links are current -- try them.
  14. https://github.com/JimmyDansbo/VTUIlib/blob/2376adc9e09c4b216f3fd8aa6b7511bcc46fbf1a/vtuilib-acme.inc#L264 https://github.com/JimmyDansbo/VTUIlib/blob/2376adc9e09c4b216f3fd8aa6b7511bcc46fbf1a/vtuilib-ca65.inc#L286 https://github.com/JimmyDansbo/VTUIlib/blob/2376adc9e09c4b216f3fd8aa6b7511bcc46fbf1a/vtuilib-generic.asm#L349
×
×
  • Create New...

Important Information

Please review our Terms of Use