File tree Expand file tree Collapse file tree 2 files changed +9
-6
lines changed
examples/MeasureCalibrationParameters Expand file tree Collapse file tree 2 files changed +9
-6
lines changed Original file line number Diff line number Diff line change 1919
2020#include " Arduino_LTR381RGB.h"
2121
22- int maxR = 0 ;
23- int maxG = 0 ;
24- int maxB = 0 ;
22+ int maxR = 0x000000 ;
23+ int maxG = 0x000000 ;
24+ int maxB = 0x000000 ;
2525
26- int minR = 255 ;
27- int minG = 255 ;
28- int minB = 255 ;
26+ int minR = 0x0FFFFFF ;
27+ int minG = 0x0FFFFFF ;
28+ int minB = 0x0FFFFFF ;
2929
3030void setup () {
3131 Serial.begin (9600 );
Original file line number Diff line number Diff line change @@ -484,12 +484,15 @@ float LTR381RGBClass::getLuxIntTime(int resolution) {
484484int LTR381RGBClass::available () {
485485 auto res = readRegister (LTR381RGB_MAIN_STATUS);
486486 if ((res & 0x20 ) == 0x20 ) {
487+ #ifdef DEBUG
487488 Serial.println (" Power-On event happens" );
489+ #endif
488490 resetSW ();
489491#ifdef DEBUG
490492 dumpReg ();
491493#endif
492494 // clear the reading after the reset
495+ end ();
493496 begin ();
494497 return 0 ;
495498 }
You can’t perform that action at this time.
0 commit comments