Kernel 0.9.2

This commit is contained in:
Rémy GIBERT 2018-10-05 08:25:15 +02:00
parent 66f6298626
commit 006a952ac3
5 changed files with 25 additions and 9 deletions

Binary file not shown.

Binary file not shown.

View File

@ -291,6 +291,7 @@ PS0.Init >LDYAI CORE.S.PS0 Select Process 0 (Kernel)
>LDYAI K.STACKTOP >LDYAI K.STACKTOP
>STYA pStack >STYA pStack
>PUSHWI 0
>PUSHBI 0 >PUSHBI 0
>LDYAI DEV.SYS >LDYAI DEV.SYS
>SYSCALL fopen >SYSCALL fopen
@ -505,6 +506,18 @@ MemMgrInit >LDYAI Mem.MHiMem
sta CLRWRITEAUX sta CLRWRITEAUX
ldx #K.Dev.MAX*4-1
.1 stz Dev.Table.hFD,x
dex
bpl .1
ldx #K.NOD.MAX*2-1
.2 stz Nod.Table.hPath,x
dex
bpl .2
rts rts
*-------------------------------------- *--------------------------------------
* Setup AuxLC $FFFE->Kernel IRQ Handler * Setup AuxLC $FFFE->Kernel IRQ Handler

View File

@ -47,10 +47,11 @@ IO.Open.I jsr STDIO.SetMLIPathYA
bcs IO.OPEN.RTS bcs IO.OPEN.RTS
>STYA pFD >STYA pFD
stx .1+1 DEVID phx DEVID
lda (pFD) #S.FD.T lda (pFD) #S.FD.T
tax tax
pla
jmp (.3,x) jmp (.3,x)
.3 .DA STDIO.IOERR REG .3 .DA STDIO.IOERR REG
@ -154,14 +155,16 @@ K.IO.OPEN.REG.E >LDYAI S.FD.REG
sec sec
rts rts
*-------------------------------------- *--------------------------------------
IO.OPEN.CDEV jsr K.IOCTL.GetPDrv IO.OPEN.CDEV sta .1+1 A=DEVID
pha
jsr K.IOCTL.GetPDrv
.1 lda #$ff SELF MODIFIED pass A=DEVID To Driver
ldx #IOCTL.OPEN ldx #IOCTL.OPEN
.2 jsr K.IOCTL.pDrvJmp pla pass A=DEVID To Driver
jsr K.IOCTL.pDrvJmp
bcs .9 bcs .9
ldx .1+1 .1 ldx #$ff SELF MODIFIED
lda Dev.Table.hFD,x lda Dev.Table.hFD,x
.9 rts .9 rts
*-------------------------------------- *--------------------------------------

View File

@ -113,7 +113,7 @@ K.FPutS jsr STDIO.GetHFile
* `int fprintf ( hFILE stream, const char * format, ... );` * `int fprintf ( hFILE stream, const char * format, ... );`
* ## ASM * ## ASM
* **In:** * **In:**
* PrintF : (example is for printing Y,A as integer : format="Y,A= %I", 2 bytes) * PrintF : (example is for printing Y,A as integer : format="%I", 2 bytes)
* `>PUSHYA` * `>PUSHYA`
* `...` * `...`
* `>PUSHBI bytecount` * `>PUSHBI bytecount`
@ -1331,7 +1331,7 @@ STDIO.GetHFileREG
.9 rts .9 rts
*-------------------------------------- *--------------------------------------
STDIO.GetHFile tay STDIO.GetHFile tay
lda Dev.Table.hFD,y lda Nod.Table.hFD,y
beq STDIO.GetHFile.9 beq STDIO.GetHFile.9
jsr K.GetMemPtr jsr K.GetMemPtr
>STYA pFD >STYA pFD