sparkfun / SparkFun_AS7265x_Arduino_Library

An Arduino library for the trifecta of spectral sensors covering 18 discrete wavelengths from NIR to UV.
https://www.sparkfun.com/products/15050
Other
40 stars 23 forks source link

AS7265x Spectral Triad Example Sensor does not appear to be connected #20

Open obisboo opened 9 months ago

obisboo commented 9 months ago

Hello,

"AS7265x Spectral Triad Example Sensor does not appear to be connected. Please check wiring. Freezing..."

This is the message when I tried to use the sensor, also I tired with your example codes, to exclude the problem from my code. Sometimes works, but after a reset I received again the freezing message. It was working randomly, I just push reset on Arduino until the sensor start to read, but in most of the cases was not working.

After a long debugging, replace the Arduino, sensors, wires, I found the problem was with the version of the lib, in my project with v1.04 I have the freeze issues, but with v1.03 is working perfectly.

I just want to tell you what was the problem in my side, maybe others have the same issue, and for the moment this was my solution I could find.

Thank you for your work guys. Have a wonderful day.

Asadsaeed003091 commented 2 months ago

Thanks, i had the same issue for days, unluckly i changed the libray but i only tried 1.0.0 and 1.0.4 and had same issue with both of them, so i though the library is not causing that issue. But with 1.0.3 everything is working fine.

2ck commented 1 month ago

Same problem here, looks like commit 95b7893 broke things. It introduces a timeout, but the default value of 0 is already used before it is set with setIntegrationCycles, leading to an early abort after 1ms with no data available

  unsigned long startTime = millis();
  while (dataAvailable() == false)
  {
    if(millis() - startTime > maxWaitTime) return; //Sensor failed to respond
aryz-ssh commented 1 month ago

Thanks, i had the same issue for days, unluckly i changed the libray but i only tried 1.0.0 and 1.0.4 and had same issue with both of them, so i though the library is not causing that issue. But with 1.0.3 everything is working fine.

Had a similar problem as obisboo. Switched library from 1.0.4 to 1.0.3 and now works perfectly fine (for now at least). Thanks for the suggestion!

scottkildall commented 1 week ago

confirmed, same problem. 1.0.3 fixes it.