lonestar

0x10c-inspired space game based on the DCPU-16
git clone git://squid-tech.com/lonestar.git
Log | Files | Refs | README

commit 3201a064126dfa152fa634e931f1f1503c156c23
parent 6a154166664e41dbedd91e33139542db6b2dce07
Author: Josh Moore <jxm5210@rit.edu>
Date:   Mon, 18 Nov 2019 21:53:45 -0500

Add flashing lights example to rom.bin

Diffstat:
Mbin/rom.bin | 0
Abin/rom.dasm | 40++++++++++++++++++++++++++++++++++++++++
2 files changed, 40 insertions(+), 0 deletions(-)

diff --git a/bin/rom.bin b/bin/rom.bin Binary files differ. diff --git a/bin/rom.dasm b/bin/rom.dasm @@ -0,0 +1,39 @@ +; this program will flash all plugged-in lights + +HWN X +SET Y, 0 + +:whitestart +SET A, 1 +HWI Y + +SET A, 0x8000 +SET B, 0 ; counter +SET C, 0 ; indexer +:white +ADD C, A +SET [C], 0xFFFF +ADD B, 1 +SET C, B +IFG B, 0xFA0 +SET PC, blackstart +SET PC, white + +:blackstart +SET A, 0 +HWI Y +ADD Y, 1 +IFE Y, X +SET Y, 0 + +SET A, 0x8000 +SET B, 0 +SET C, 0 +:black +ADD C, A +SET [C], 0x0000 +ADD B, 1 +SET C, B +IFG B, 0xFA0 +SET PC, whitestart +SET PC, black+ \ No newline at end of file