You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
An extra 40 micro seconds (320-280) LED on time is probably required after taking reading from analogRead before it's turned off.
uint16_t GP2YDustSensor::readDustRawOnce(uint16_t waitMicroSecs)
{
// Turn on the dust sensor LED by setting digital pin LOW.
digitalWrite(this->ledOutputPin, LOW);
// Wait 0.28ms before taking a reading of the output voltage as per spec.
delayMicroseconds(waitMicroSecs);
// Record the output voltage. This operation takes around 100 microseconds.
uint16_t VoRaw = analogRead(this->analogReadPin);
// Turn the dust sensor LED off by setting digital pin HIGH.
digitalWrite(this->ledOutputPin, HIGH);
return VoRaw;
}
The text was updated successfully, but these errors were encountered:
An extra 40 micro seconds (320-280) LED on time is probably required after taking reading from analogRead before it's turned off.
The text was updated successfully, but these errors were encountered: