zn0			
			:5 dta >zestaw0,>zestaw1,>zestaw2,>zestaw3,>zestaw4

dli0
			pha

_start_char	equ *+1
			lda #$88
			sta wsync
			sta chbase

			mva #$08 colpf1
kol1		equ *+1			
			mva #$ba colpf2
			mva #$14 colbak
_licz_dli_start	equ *+1
			mva #0 _licz_dli
			
			mwa #dli dliv
			lda vscrol1
_rapidus	equ *+1			
			cmp #7
			bne @+
			txa
			pha
			lda #64
			sta nmien			;zablokuj dli
			
			ldx _licz_dli
			lda zn0,x
			sta wsync
			sta chbase
			lda #192
			sta nmien			;wlacz dli
			inc _licz_dli
			pla
			tax

@			pla
			rti



dli			pha
			txa
			pha

_licz_dli	equ *+1			
			ldx #0
_end_dli	equ *+1			
			cpx #20
			beq @+
			lda zn0,x
_rapidus1			
			:3 nop
		
			
			sta chbase
			inc _licz_dli
			
			pla
			tax
			pla
			rti
			
@			lda #0
			sta wsync
			sta colbak
			sta colpf2
			lda #$0c
			sta colpf1

			lda #>znaki
			sta chbase
			
					
			pla
			tax
			pla
			rti


nmi			bit nmist
			bpl *+5
			jmp (dliv)
			jmp (vbiv)	

vbi
			pha
			inc zegar
			mwa #dli0 dliv

			pla
			rti
			

irq			rti