conio and most other stuff working now

This commit is contained in:
mrdudz
2015-11-29 01:14:59 +01:00
parent 88e7b5776a
commit 9fbf8a4299
35 changed files with 2205 additions and 737 deletions

33
libsrc/gamate/clock.s Normal file
View File

@@ -0,0 +1,33 @@
;
; clock_t clock (void);
;
.include "gamate.inc"
.include "extzp.inc"
.export _clock
.forceimport ticktock
.importzp sreg
.constructor initclock
.proc _clock
lda tickcount+3
sta sreg+1
lda tickcount+2
sta sreg
ldx tickcount+1
lda tickcount
rts
.endproc
.segment "INIT"
initclock:
lda #0
ldx #3
@lp: sta tickcount,x
dex
bpl @lp
rts