title: EASy68K Assembly - first program errors
body: <p>I'm new to assembly language, so I'm having a little trouble with my first program. I am supposed to basically recreate the following code, except in assembly language obviously. Can anyone help me fix the errors and help me get my program to work properly? I think I am close. </p>
  
  <p>Original non-assembly Code:</p>
  
  <pre><code>Q = 7;
  P = 15;  // also test on P = 14 and P = 6
  if (P &gt; 12)
    P = 8 * P + 4;   // Requirement: use ASL for multiplied by 8
  else
    P = P - Q;
  print P;
  </code></pre>
  
  <p>Here is what I have so far, but I'm getting errors. I'll post the errors at the bottom.</p>
  
  <pre><code>START   ORG     $1000   //Program starts at loc $1000
  IF      CMP     #12,P   //Is P &gt; 12?
          BLE     ENDIF   //If P &lt; 12, go to ENDIF
          ASL     #3,P    //Shift left 3 times (Multiply P * 8)
          ADD     #4,P    //P + 4 
  ENDIF   SUB     Q,P     //P - Q
  
  * Data section
      ORG $2000    //Data starts at loc 2000
  P   DC.W    15  //int P = 15;
  Q   DC.W    7   //int Q = 7;
      END START
  </code></pre>
  
  <p>Line 4: ERROR: Invalid addressing mode 
  Line 7: ERROR: Invalid addressing mode</p>