Advertisement
NovaYoshi

mouse change sensitivity

Mar 19th, 2014
179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. ; X is the controller number
  2.  
  3. lda mousebyte2,x ; check speed in the second byte read from the mouse
  4. and #%00110000
  5. lsr
  6. lsr
  7. lsr
  8. lsr
  9. cmp #2 ; 2 is fast
  10. bne :+ ; change to the next speed
  11.   lda #1    ; turn on latch
  12.   sta $4016
  13.   lda $4016,x  ; read from controller with latch on
  14.   lda #0
  15.   sta $4016 ; turn off latch
  16. :
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement