1
0
mirror of https://github.com/cc65/cc65.git synced 2026-03-10 17:21:49 +00:00

Merge pull request #2919 from polluks/c16

Combine C16 and Plus/4 source
This commit is contained in:
Bob Andrews
2026-02-11 19:47:04 +01:00
committed by GitHub
2 changed files with 2 additions and 44 deletions

View File

@@ -1,26 +1 @@
;
; Ullrich von Bassewitz, 06.08.1998
;
; unsigned char kbhit (void);
;
.export _kbhit
.include "plus4.inc"
.proc _kbhit
ldx #0 ; High byte of return is always zero
lda KEY_COUNT ; Get number of characters
ora FKEY_COUNT ; Or with number of chars from function keys
beq L9
lda #1
L9: rts
.endproc
.include "../plus4/kbhit.s"

View File

@@ -1,18 +1 @@
;
; 2002-11-05, Ullrich von Bassewitz
; 2015-09-11, Greg King
;
; void __randomize (void);
; /* Initialize the random number generator */
;
.export ___randomize
.import _srand
.include "plus4.inc"
___randomize:
ldx TED_VLINELO ; Use TED rasterline as high byte
lda TIME+2 ; Use 60HZ clock as low byte
jmp _srand ; Initialize generator
.include "../plus4/randomize.s"