class pah8011 for mbed
Diff: pixart_pah8011.h
- Revision:
- 5:37451de228e4
- Parent:
- 4:cbc49829af39
- Child:
- 6:d196b612b14a
--- a/pixart_pah8011.h Fri Oct 27 06:05:38 2017 +0000 +++ b/pixart_pah8011.h Fri Oct 27 08:21:32 2017 +0000 @@ -12,6 +12,8 @@ class pah8011 { public: + typedef void (*DEBUG_PRINT_HANDLE)(const char *fmt, ...); + struct task_result { // ppg int32_t *data; @@ -26,7 +28,9 @@ pah8011(); ~pah8011(); - bool init(I2C &i2c, Serial *serial = NULL, uint8_t slave_id = 0x15); + void enable_debug_print(DEBUG_PRINT_HANDLE handler); + + bool init(I2C &i2c, uint8_t slave_id = 0x15); // operations bool enable_ppg();