Z80 Assembly programming for the TI-83

The TI-83 is a bit of an oddity... with a full blown Z80 and large keyboard, it's a great little handheld - but with it's slow screen refresh it's not exactly what you'll want to program games on!

Still, as one of the longest running z80 platforms, it deserves a lot of respect!
Cpu 6mhz Z80
Ram 32k
Resolution   
96x64 2 color   12x8 chars in 8x8 mode
16x10.6 in 6x6 mode
Sound chip NONE!
Chibiakumas Tutorials:

Lesson H7- Hello World on the TI-83
   
Lesson P1 - Basic Firmware Text functions

Lesson P5 - Bitmap graphics on the TI-83 and MSX

Lesson P7 - Keyreading on the MSX, Enterprise and TI-83



IY register

The IY register is used by the operating system... so it's probably best to leave it alone!

bin28xp

If you want to convert a binary to a valid program you can run on your TI, you need to convert it to an 8xp file.

We can use bin28xp to do this, I did not write it, however there was a bug in the original which meant it corrupted larger files, you can get my modified version here

Ports

OUT PORT Function Bits Details
&00 Link

&01 Keyboard

(Out=Row Select / IN = Key results)
&02 Status Port/Interrupt Acknowledge

&03 Interrupt Mask

&04 Memory Map / Interrupt

&05 RAM Page(SE) Port 16 Config/Link Assist(83+)

&06 Memory Page A

&07 Memory Page B

&08 Link Assist Enable

&09 Link Assist Status/CPU Speed 0 Signaling Rate

&0A Link Assist Input Buffer/CPU Speed 1 Signaling Rate

&0B CPU Speed 2 Signaling Rate

&0C CPU Speed 3 Signaling Rate

&0D Link Assist Output Buffer

&0E MemA High Flash Address

&0F MemB High Flash Address

&10 LCD Command / Status Port %BSDR--YI B=Busy S=Size(6/8 pixel)
D=DisplayOn R=Reset
Y=XY auto I=AutoDec/Inc
&11 LCD Data %DDDDDDDD 
/ %--DDDDDD
Pixel Data (8/6 bits)
&12 LCD Command Mirror

&13 LCD Data Mirror

&14 Flash Control

&15 ASIC Version

&16 Flash Page Exclusion

&18-1F MD5 Calculation

&20 CPU Speed Port

&21 Flash Size/ RAM Size

&22 Flash Lower Limit

&23 Flash Upper Limit

&24 Flash Execution Limits High Bit

&25 RAM Execution Lower Limit

&26 RAM Execution Upper Limit

&27 Block Memory Mapping C000h

&28 Block Memory Mapping 8000h

&29 LCD Delay (6 MHz)

&2A LCD Delay(15 MHz)

&2B LCD Delay(15 MHz)(02)

&2C LCD Delay(15 MHz)(03)

&2D 32768Hz Crystal Control

&2E Memory Access Delay

&2F LCD Wait Delay

&30-38 Timers

&39 GPIO Configuration

&3A GPIO Read/Write

&40 Clock Control

&41-44 Clock Set

&45-48 Clock Read

&4A D- Control

&4C USB Controller Status

&4D USB Line State

&54 USB Controller Control

&55 USB Interrupt State

&56 USB Line Events

&57 USB Line Event Mask

&5A USB Presentation Link Port Mirroring Enable

&5B USB Protocol Interrupt Enable

&60-7F 40-5F Mirrors

&80 USB Device Address

&82 USB Write-Pipe Events

&83 USB Write-Pipe Events (continued)

&84 USB Read-Pipe Events

&85 USB Read-Pipe Events (continued)

&86 USB Miscellaneous Events

&87 USB Output-Enabled Pipes

&88 USB Output-Enabled Pipes (continued)

&89 USB Input-Enabled Pipes

&8A USB Input-Enabled Pipes (continued)

&8B USB Events Mask

&8C-8D USB Frame Counter

&8E USB Pipe Number

&8F VBus Control

&90 USB Write Packet Size

&91 USB Write Command/Status

&93 USB Read Packet Size

&96 USB Data-Received Counter

&98 USB Write Endpoint Type/Address

&9A USB Read Endpoint Type/Address

Graphics Commands

Command (OUT to &10) Action
&00 Configure six bits per word
&01 Configure eight bits per word
&02 Turn off
&03 Turn on
&04 X auto-decrement (X is Down the screen)
&05 X auto-increment (X is Down the screen)
&06 Y auto-decrement (Y is Across the screen)
&07 Y auto-increment (Y is Across the screen)
&08-&0B Power supply enhancement. &08 is lowest.
&10-&13 Power supply level. &10 is lowest.
&14-&17 Unknown
&18 test mode
&19-&1B Unknown
&1C-&1F Enter test mode
&20-&33 Set Horizontal column nn for next write (Out data to port &11)
&34-&3F Unknown
&40-&7F Set Z-address
&80-&BF Set Vertical row nn for next write (Out data to port &11)
&C0-&FF Set contrast

Memory Map

Address Function
&0000-3FFF Flash Page 0
&4000-7FFF Memory Bank A (MemA)
&8000-BFFF Memory Bank B (MemB) - Program runs from &9D95
&C000-FFFF RAM Page 0

Keyreading on the TI-83

The keyboard is connected to port 1 on the TI, we select the row, and read the data back using this port,
We write this data out, then read in the line contents, and save them to the array

Row
Out &1
IN &1
bit 7   bit 6     bit 5     bit 4   bit 3 bit 2 bit 1 bit 0
%10111111 Del Mode 2nd Y= Window ZOOM Trace Graph
%11011111 Alpha Math x-1 x2 Log Ln Sto
%11101111 X, T, θ, n Apps Sin , 7 4 1 0
%11110111 Stat Prgm Cos ) 8 5 2 .
%11111011 -
Vars Tan ( 9 6 3 (-)
%11111101 - Clear ^ - + Enter
%11111110 - - - - Up Right Left Down

TI-83 Links

WabbitEmu - Fine Ti-83 emulator - you'll need your own rom files from somewhere!
Learn ASM in 28 days - I learned from this tutorial, it's a great guide that covers the Ti-83

 

View Options
Default Dark
Simple (Hide this menu)
Print Mode (white background)

Top Menu
***Main Menu***
Youtube channel
Patreon
Introduction to Assembly (Basics for absolute beginners)
Amazon Affiliate Link
AkuSprite Editor
ChibiTracker
Dec/Bin/Hex/Oct/Ascii Table

Alt Tech
Archive.org
Bitchute
Odysee
Rumble
DailyMotion
Please note: I wlll upload more content to these alt platforms based on the views they bring in

Z80 Content
***Z80 Tutorial List***
Learn Z80 Assembly (2021)
Learn Z80 Assembly (old)
Hello World
Simple Samples
Advanced Series
Multiplatform Series
Platform Specific Series
ChibiAkumas Series
Grime Z80
Z80 Downloads
Z80 Cheatsheet
Sources.7z
DevTools kit
Z80 Platforms
Amstrad CPC
Elan Enterprise
Gameboy & Gameboy Color
Master System & GameGear
MSX & MSX2
Sam Coupe
TI-83
ZX Spectrum
Spectrum NEXT
Camputers Lynx

6502 Content
***6502 Tutorial List***
Learn 6502 Assembly
Advanced Series
Platform Specific Series
Hello World Series
Simple Samples
Grime 6502
6502 Downloads
6502 Cheatsheet
Sources.7z
DevTools kit
6502 Platforms
Apple IIe
Atari 800 and 5200
Atari Lynx
BBC Micro
Commodore 64
Commodore PET
Commander x16
Super Nintendo (SNES)
Nintendo NES / Famicom
PC Engine (Turbografx-16)
Vic 20

68000 Content
***68000 Tutorial List***
Learn 68000 Assembly
Hello World Series
Platform Specific Series
Simple Samples
Grime 68000
68000 Downloads
68000 Cheatsheet
Sources.7z
DevTools kit
68000 Platforms
Amiga 500
Atari ST
Neo Geo
Sega Genesis / Mega Drive
Sinclair QL
X68000 (Sharp x68k)

8086 Content
Learn 8086 Assembly
Platform Specific Series
Hello World Series
Simple Samples
8086 Downloads
8086 Cheatsheet
Sources.7z
DevTools kit
8086 Platforms
Wonderswan
MsDos

ARM Content
Learn ARM Assembly
Learn ARM Thumb Assembly
Platform Specific Series
Hello World
Simple Samples
ARM Downloads
ARM Cheatsheet
Sources.7z
DevTools kit
ARM Platforms
Gameboy Advance
Nintendo DS
Risc Os

Risc-V Content
Learn Risc-V Assembly
Risc-V Downloads
Risc-V Cheatsheet
Sources.7z
DevTools kit

MIPS Content
Learn Risc-V Assembly
Platform Specific Series
Hello World
Simple Samples
MIPS Downloads
MIPS Cheatsheet
Sources.7z
DevTools kit
MIPS Platforms
Playstation
N64

PDP-11 Content
Learn PDP-11 Assembly
Platform Specific Series
Simple Samples
PDP-11 Downloads
PDP-11 Cheatsheet
Sources.7z
DevTools kit
PDP-11 Platforms
PDP-11
UKNC

TMS9900 Content
Learn TMS9900 Assembly
Platform Specific Series
Hello World
TMS9900 Downloads
TMS9900 Cheatsheet
Sources.7z
DevTools kit
TMS9900 Platforms
Ti 99

6809 Content
Learn 6809 Assembly
Learn 6309 Assembly
Platform Specific Series
Hello World Series
Simple Samples
6809 Downloads
6809/6309 Cheatsheet
Sources.7z
DevTools kit
6809 Platforms
Dragon 32/Tandy Coco
Fujitsu FM7
TRS-80 Coco 3
Vectrex

65816 Content
Learn 65816 Assembly
Hello World
Simple Samples
65816 Downloads
65816 Cheatsheet
Sources.7z
DevTools kit
65816 Platforms
SNES

eZ80 Content
Learn eZ80 Assembly
Platform Specific Series
eZ80 Downloads
eZ80 Cheatsheet
Sources.7z
DevTools kit
eZ80 Platforms
Ti84 PCE

IBM370 Content
Learn IBM370 Assembly
Simple Samples
IBM370 Downloads
IBM370 Cheatsheet
Sources.7z
DevTools kit

Super-H Content
Learn SH2 Assembly
Hello World Series
Simple Samples
SH2 Downloads
SH2 Cheatsheet
Sources.7z
DevTools kit
SH2 Platforms
32x
Saturn

PowerPC Content
Learn PowerPC Assembly
Hello World Series
Simple Samples
PowerPC Downloads
PowerPC Cheatsheet
Sources.7z
DevTools kit
PowerPC Platforms
Gamecube

Work in Progress
ChibiAndroids

Misc bits
Ruby programming









Buy my Assembly programming book
on Amazon in Print or Kindle!


Buy my Assembly programming book





Available worldwide!
Search 'ChibiAkumas' on
your local Amazon website!
Click here for more info!


























































































Buy my Assembly programming book
on Amazon in Print or Kindle!


Buy my Assembly programming book





Available worldwide!
Search 'ChibiAkumas' on
your local Amazon website!
Click here for more info!



































































































Buy my Assembly programming book
on Amazon in Print or Kindle!


Buy my Assembly programming book





Available worldwide!
Search 'ChibiAkumas' on
your local Amazon website!
Click here for more info!