     1 000000           ; > SrchMem : search for value in memory (assume value on even address)
     2 000000           ;
     3 000000           ; All in P.I.C. !
     4 000000           ;
     5 000000 005000            CLR     R0
     6 000002 012701            MOV     #2,R1           ; value for adjustment
     6 000004 000002    
     7 000006 022720    LABEL1: CMP     #O177570,(R0)+  ; look, and point to next
     7 000010 177570    
     8 000012 001405            BEQ     LABEL2          ; if found, go to finish
     9 000014 022700            CMP     #O160000,R0     ; check we're not wandering into I/O area
     9 000016 160000    
    10 000020 001372            BNE     LABEL1          ; if not, try again
    11 000022 000000    HALT:   HALT                    ; else stop!
    12 000024 000776            BR HALT                 ; can't continue!
    13 000026 160100    LABEL2: SUB     R1,R0           ; found, but R0 points past it
    14 000030 000000            HALT                    ; finished!
    15 000032 060100            ADD     R1,R0           ; re-starting, so point to next
    16 000034 000764            BR      LABEL1
