Navigation
Home & news
Random page
All pages
Site search:
Databases
Fortune cookies
Haikus
SID themes
Page collections
Blag
Chip music
Games
Hardware projects
Music downloads
Obfuscated programming
Piano music
Sane programming
Scene productions
SID related pages
Software downloads
Video downloads
Featured pages
Autosokoban
Beagleboard VGA
Binary Art
Brainfuck
Chipophone
Chopin romance
Craft
Fratres
Hardware chiptune
Klämrisk Hero
Lampslide
Making the Chipophone
Phasor
Reverberations
Slaepwerigne
Spellbound
Swan
TTY demystified
Turbulence
Forum
Register
Log in
Latest comments
Feedback
  • Swedish content
  • Personal content
  • Offensive content

Getting numeric input

Back to the TI-83 page

This is done in about the same way as getting string input. Start by putting the prompt at 821ch:

        ld      de,821ch                ;put the prompt here
        ld      hl,prompt
        ld      bc,prompt_len           ;length of prompt, max = 16
        ldir

Then call PGMIO_EXEC, but with a different command in ASM_IND_CALL:

        ld      a,1                     ;code for NUMERIC input
        ld      (ASM_IND_CALL),a

        call    PGMIO_EXEC

The input is automatically parsed as an expression, and the result is placed in OP1.

        call    _formDisp               ;display it
        ret

prompt:         .db \"Inp:\",0
prompt_len      =   $-prompt"}

Discuss this page

There are no comments here yet.