DFRobot / DFRobot_AS7341

We live in a colorful world, but how much do you really know about color? You eyes may deceive you, while the sensors don’t lie. This AS7341sensor can tell you the truth about color. <br> AS7341 Visible Light Sensor employs the new generation of AS7341 spectral sensor IC launched by the well-known ARM company. The sensor features eight channels for the visible light, one channel for near-IR, and one channel without a filter. Also it integrates a dedicated channel to detect ambient light flicker. Besides that, this sensor comes with 6 independent 16-bit ADC channels for data processing in parallel. The two on-board extra-bright LEDs can supply light in dark environment.
MIT License
10 stars 3 forks source link

Function `DFRobot_AS7341::getWtime()` fails with `maybe-uninitialized` #2

Open fdobrovolny opened 11 months ago

fdobrovolny commented 11 months ago

Using the default platformio configuration, the library cannot be built.

.pio/libdeps/esp32dev/DFRobot_AS7341/DFRobot_AS7341.cpp: In member function 'float DFRobot_AS7341::getWtime()':
.pio/libdeps/esp32dev/DFRobot_AS7341/DFRobot_AS7341.cpp:537:10: error: 'value' may be used uninitialized in this function [-Werror=maybe-uninitialized]
   return value;
          ^~~~~
cc1plus: some warnings being treated as errors
*** [.pio/build/esp32dev/lib3fc/DFRobot_AS7341/DFRobot_AS7341.cpp.o] Error 1