Arnaud VALLEY / Mbed 2 deprecated Pinscape_Controller_V2_arnoz

Dependencies:   mbed FastIO FastPWM USBDevice

Revision:
10:976666ffa4ef
Parent:
9:fd65b0a94720
Child:
11:bd9da7088e6e
diff -r fd65b0a94720 -r 976666ffa4ef USBJoystick/USBJoystick.h
--- a/USBJoystick/USBJoystick.h	Mon Aug 18 21:46:10 2014 +0000
+++ b/USBJoystick/USBJoystick.h	Sat Aug 23 01:24:36 2014 +0000
@@ -107,6 +107,18 @@
          * @returns true if there is no error, false otherwise
          */
          bool update(int16_t x, int16_t y, int16_t z, uint16_t buttons, uint16_t status);
+         
+         /**
+         * Write an exposure report.  We'll fill out a report with as many pixels as
+         * will fit in the packet, send the report, and update the index to the next
+         * pixel to send.  The caller should call this repeatedly to send reports for
+         * all pixels.
+         *
+         * @param idx current index in pixel array, updated to point to next pixel to send
+         * @param npix number of pixels in the overall array
+         * @param pix pixel array
+         */
+         bool updateExposure(int &idx, int npix, const uint16_t *pix);
  
          /**
          * Write a state of the mouse
@@ -156,7 +168,7 @@
          int16_t _y;     
          int16_t _z;
          uint16_t _buttons;
-         uint8_t _status;
+         uint16_t _status;
          
          void _init();                 
 };