title: clearing memory locations with pic microcontroller
body: <p>I am a beginner with asm and embedded systems. I was looking at code which is meant to clear memory locations using the "indirection" register (or something like that - not sure). The code goes like:</p>
  
  <pre>
      movlw 0x20
      movwf FSR
  loop    clrf INDF
      incf FSR, F
      btfsc FSR, 7
      goto loop
  </pre>
  
  <p>I don't get the <code>incf FSR, F</code> part. The instruction <code>incf</code> takes two operands; it increments value in the first location, and stores the result in the 2nd. In this case <code>F</code> will have the incremented value, then why do we do a test on <code>FSR</code>? </p>