
	; jsr print
	; dta c'Ala ma kota',$9b,0
	; next instructions
print  .proc
	stx ?_tmpx
        clc
        pla
        adc #$01
        sta ?strv
        pla
        adc #$00
        sta ?strv+1

?strv	equ *+1
	lda $ffff
	bne ?prt
	lda ?strv+1
	pha
	lda ?strv
	pha
	rts
?prt	jsr $f2b0
	inw ?strv
	bne ?strv-1
	ldx ?_tmpx:#0
	rts	
	.endp

printhex .proc
	pha
	stx ?_tmpx
	:4 lsr
	jsr HEX2INT
	jsr $f2b0
	pla
	and #$0f
	jsr HEX2INT
	jsr $f2b0
	ldx ?_tmpx
	rts
?_tmpx	.byte 0

HEX2INT 
	php
	sei
	SED
        CMP #$0A
        ADC #'0'
        CLD
	plp
                        ; wynik dzialania w regA
        rts
	.endp

printnl	.proc
	lda #$9b
	jmp $f2b0
	.endp
