first step towards string expression evaluation
This commit is contained in:
1 parent
801755c9a8
commit
48eec7d56e
5 files changed
+89
-13
No files matched your search
@@ -0,0 +1,40 @@
|
||||
// #LAYOUT# STD * #TAKE
|
||||
// #LAYOUT# X16 BASIC_0 #TAKE-OFFSET 2000
|
||||
// #LAYOUT# * BASIC_0 #TAKE
|
||||
// #LAYOUT# * * #IGNORE
|
||||
|
||||
|
||||
// Well-known BASIC routine, described in:
|
||||
//
|
||||
// - [CM64] Computes Mapping the Commodore 64 - page 102
|
||||
// - https://sta.c64.org/cbm64basconv.html
|
||||
//
|
||||
// Output:
|
||||
// - VALTYP - $00 = floating number, $FF = string
|
||||
// - INTFLG (XXX float/integer, probably)
|
||||
// - for float: FAC1
|
||||
// - for string: __FAC1 + 0 = length, __FAC1 + 1 = pointer to string
|
||||
|
||||
// XXX provide documentation and implementation
|
||||
|
||||
FRMEVL:
|
||||
|
||||
// XXX for now we just report dummy string
|
||||
|
||||
lda #$FF
|
||||
sta VALTYP
|
||||
|
||||
lda #$0B
|
||||
sta __FAC1 + 0
|
||||
|
||||
lda #<dummy_text
|
||||
sta __FAC1 + 1
|
||||
|
||||
lda #>dummy_text
|
||||
sta __FAC1 + 2
|
||||
|
||||
rts
|
||||
|
||||
dummy_text:
|
||||
|
||||
.text "LOREM IPSUM"
|
||||
@@ -0,0 +1,3 @@
|
||||
|
||||
This routine is desribed in Mapping the C64, page 102, and used at least by CCGMS terminal software - see here:
|
||||
- https://raw.githubusercontent.com/spathiwa/ccgmsterm/master/original/5a.gs
|
||||
Reference in new issue
Block a user