TI's calculators let you program them in z80 assembly! Unfortunately, TI didn't include a way to program in it on-calc using mnemonics (there are ways to, though. More on that later). You can, however, type machine code directly into the TI-BASIC program editor by starting a program with the AsmPrgm
(or Asm84CPrgm
, or Asm84CEPrgm
, depending on the calc you have) token, then typing a series of opcodes that correspond to assembly instructions. For instance, here's a do-nothing program:
AsmPrgm
00
C9
Which translates directly (disregarding the necessary preprocessor directives) into:
NOP ;no-op
RET ;return to the OS. If this is omitted, the program will remain in execution forever, requiring a RAM clear to exit
This page has a bit more info on that, but note that "hex codes" is a misnomer, since "hex" has nothing specifically to do with z80 assembly.
If you have a monochrome (not the C Silver Edition or CE) calculator, though, I'd strongly recommend downloading Mimas, an on-calc assembly editor-- actual assembly, meaning it uses mnemonics! And it contains the OS include file, which assigns keywords to all the important system memory locations and "b_call()
s" (which TI placed at rst 0x28
), which are system routines TI put in the OS to make life easier.
There also exists a C compiler for the new 84 Plus CE calculator, if you happen to have that model. It's a computer program, though, so again (sadly) no on-calc C programming.