global_code: !debugger = 2 !Ram = $77 ;>input a number of what ram address you want to read. !StatusBarPos = $7FA000 ;>the position it will appear on status bar. !scratchram = $0000 !assbram = $7FA000 if !debugger = 0 then RTS else if !debugger = 1 then LDA !Ram ;\every 16th number increments the 1st digit. LSR #$04 ;| STA !StatusBarPos ;/ LDA !Ram ;\limit it to #$00-#$0F on 2nd digit digit. AND #$0F ;| STA !StatusBarPos+2 ;/ RTS else if !debugger = 2 then REP #$20 STZ !scratchram ;\show zeros STZ !scratchram+2 ;|(placed here so the set bits STZ !scratchram+4 ;|checks will happen last) STZ !scratchram+6 ;/ SEP #$20 LDY #$01 ;>show ones (use Y to remove duplicates) LDA !Ram ;\display ones on status bar if set BPL + ;| STY !scratchram ;| + ASL A ;| BPL + ;| STY !scratchram+1 ;| + ASL A ;| BPL + ;| STY !scratchram+2 ;| + ASL A ;| BPL + ;| STY !scratchram+3 ;| + ASL A ;| BPL + ;| STY !scratchram+4 ;| + ASL A ;| BPL + ;| STY !scratchram+5 ;| + ASL A ;| BPL + ;| STY !scratchram+6 ;| + ASL A ;| BPL + ;| STY !scratchram+7 ;/ + LDA !scratchram STA !assbram LDA !scratchram+1 STA !assbram+2 LDA !scratchram+2 STA !assbram+4 LDA !scratchram+3 STA !assbram+6 LDA !scratchram+4 STA !assbram+8 LDA !scratchram+5 STA !assbram+10 LDA !scratchram+6 STA !assbram+12 LDA !scratchram+7 STA !assbram+14 RTS endif