; include file
#dontinclude






; coco main
	opt	forwardrefmax
#include	coco\main_lib.txt
#include	coco\disk_lib.txt
#include	coco\cg3_display.txt
#include	coco\sidchip.txt
#include	coco\joystick_lib.txt

#memstart	28672	;$7500


	org	$3500	;mem start?
start
	sg4_setdisplay()


	lda	#2
	sta	page
mainlp

	cls(page,#1)

	keystring(#0)
	ldx	#keystring_dump
	lda	0,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#0,#myword)

	lda	1,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#32,#myword)

	lda	2,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#64,#myword)

	lda	3,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#96,#myword)

	lda	4,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#128,#myword)

	lda	5,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#160,#myword)

	lda	6,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#192,#myword)

	lda	7,x
	sta	key_chk
	binstring(key_chk,#myword)
	print(page,#1,#224,#myword)



	sg4_nosync(page)
	inc	page
	if	b,page>#2
	clr	page
	endif

	lbra	mainlp

def	myword	string	10
def	key_chk	byte
def	page	byte

; end of program
cocoromend



	end	start



