Interface to access to Avago ADNS-9500 laser mouse sensors.

Fork of ADNS9500 by Chris Majoros

Revision:
12:61b07ad45dc1
Parent:
11:07a39997a421
Child:
13:6d0642367fc1
diff -r 07a39997a421 -r 61b07ad45dc1 adns9500.cpp
--- a/adns9500.cpp	Thu Jul 12 13:56:54 2012 +0000
+++ b/adns9500.cpp	Sat Sep 29 22:36:29 2012 +0000
@@ -301,12 +301,12 @@
             WAIT_TSRR();
             int dxl = spiReceive(DELTA_X_L);
             WAIT_TSRR();
-            dx += ADNS9500_INT16(spiReceive(DELTA_X_H), dxl);
+            dx = ADNS9500_INT16(spiReceive(DELTA_X_H), dxl);
             
             WAIT_TSRR();
             int dyl = spiReceive(DELTA_Y_L);
             WAIT_TSRR();
-            dy += ADNS9500_INT16(spiReceive(DELTA_Y_H), dyl);
+            dy = ADNS9500_INT16(spiReceive(DELTA_Y_H), dyl);
         }
 
         WAIT_TSCLKNCS();