(Note: This is ASM for my Calculator; TI-83+. Unless you are familiar with it, some things may confuse you.)
I am working on a calculator program (a game
), and I needed some arrow symbol in a specific spot; this arrow thing can't be put in any string with TI-BASIC (normal Texas Instruments calculator programming). No problem, just make an ASM program to display it in all the correct spots.
I make that program, and when I go to test it instead of just displaying the arrow (05), it displays 3 characters (45,C9,05). The 45C9 comes from the two characters before the 05 (…EF61
45C90500).
Did I do something wrong? Is there any character I can change to correct this?
I tried changing a few numbers that could make sense; but it had no effect, made the program do nothing at all, or it crashed.
[codebox].list
#define equ .equ
#define EQU .equ
#define end .end
#include RPG.inc
.nolist
#define bcall(label) RST 28h \ .dw label
.org $9D93
.db $BB,$6D
ld a,6
ld (penCol),a
bcall(_ThetaName)
bcall(_RclVarSym)
bcall(_ConvOP1)
dec a
jr z,new
dec a
jr z,file1
dec a
jr z,file2
dec a
jr z,file3
dec a
jr z,delete
dec a
jr z,options
ret
new:
ld a,6
ld (penRow),a
jp outPutIt
file1:
ld a,11
ld (penRow),a
jp outPutIt
file2:
ld a,17
ld (penRow),a
jp outPutIt
file3:
ld a,23
ld (penRow),a
jp outPutIt
delete:
ld a,29
ld (penRow),a
jp outPutIt
options:
ld a,35
ld (penRow),a
jp outPutIt
outPutIt:
ld hl,string
bcall(_vputs)
ret
string:
.db $05,$00
.end
END[/codebox]
If it helps this is the stuff in the include file:
CODE
_ConvOP1 EQU 4AEFh
_RclVarSym equ 4ae3h
_ThetaName EQU 427Ch
_VPutS EQU 4561h
penCol EQU 86D7h
penRow EQU 86D8h
Compiled Hex:
CODE
BB6D3E0632D786EF
7C42EFE34AEFEF4A
3D28103D28153D28
1A3D281F3D28243D
2829C93E0632D886
C3E69D3E0B32D886
C3E69D3E1132D886
C3E69D3E1732D886
C3E69D3E1D32D886
C3E69D3E2332D886
C3E69D21ED9DEF61
45C90500
ADDITION:
I found the line. "C3E69D21
ED9DEF61" to "C3E69D21
EF9DEF61" (Near the bottom).
I blame the compiler.