I recently acquired an original TI-84 Plus and have been meaning to learn asm programming for it. For the most part I've been reading the 28 day guide although I've been reading James Malcolm's guide as well. For my toolchain I've been using the Doors CS SDK as it seems easier to set up and fairly modern. I copy the following example program into a new asm file:

Code:

.nolist
#include "ti83plus.inc"
#define    ProgStart    $9D95
.list
.org    ProgStart - 2
    .db    t2ByteTok, tAsmCmp
    b_call(_ClrLCDFull)
    ld    hl, 0
    ld    (PenCol), hl
    ld    hl, msg
    b_call(_PutS)            ; Display the text
    b_call(_NewLine)
    ret

msg:
    .db "Hello world!", 0
.end
.end

I run compile helloworld.asm, get my .8xp file send it to my calc using TiLP2, which I'm pretty sure is set up fine since it has uploaded other stuff fine.
I can run it through prgmHELLO or Asm(prgmHELLO and either way the program seems to run, immediately printing Done and returning to the shell. It never actually prints "hello word". In fact I know the program is being sent because if I intentionally write a program to crash the calculator, it does crash. Does anyone know what's going on?
Thanks
As I saw pointed out in chat but nobody bothered posting, this is caused by MathPrint messing with how text gets displayed. You can disable it manually in the mode screen, and optionally disable it programmatically. Wikiti says:
Quote:
5, (iy+44h) MathPrint. You should clear the screen as well as fill CmdShadow and TextShadow 20h's if you change this flag.

So this should do the job to disable MathPrint in a program:

Code:
    res 5, (iy + 44h)
    ld hl, cmdShadow
    ld b, 128
clrCmdShadow:
    ld (hl), 20h
    inc hl
    djnz clrShadow
    ld hl, textShadow
    ld b, 128
clrTextShadow:
    ld (hl), 20h
    inc hl
    djnz clrTextShadow
Hey there.
In addition to what Tari suggested, replace "ld (pencol),hl" by "ld (currow),hl".
Cheers.
Thank you all. That's just the bit of help I needed. Just being able to make programs and see their output means I can finally get to the interesting programming bits.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement