	.code
	.bank 82
	.org $7700
l7700_00: SEC     
          SBC     <$f9
          STA     <$fc
          BCS     l7709_00
          DEC     <$fd
l7709_00: STZ     <$fa
          LDA     <$fd
          CMP     <$f9
          BNE     l7717_00
          LDA     <$fc
          CMP     <$f8
          BEQ     l771b_00
l7717_00: LDA     #$01
          STA     <$fa
l771b_00: LDA     #$04
          STA     <$f8
          LDA     #$80
          STA     <$f9
          LDA     #$4a
          STA     <$fc
          LDA     #$77
          STA     <$fd
          CLY     
l772c_00: LDA     [$f8], Y
          CMP     [$fc], Y
          BEQ     l7736_00
          LDA     #$01
          STA     <$fa
l7736_00: INY     
          CPY     #$0a
          BNE     l772c_00
          LDA     <$fa
          CMP     #$00
          BEQ     l7746_00
          INX     
          CPX     #$03
          BCC     l76d4_00
l7746_00: PLY     
          PLX     
          PLP     
          RTS     
