fix(power): Add support for capacitors on ADC for BVD

Add a little delay so any capacitors connected to the ADC for the BVD can charge up when using power_gpios

Co-authored-by: Jasper Smit <jrhrsmit@gmail.com>
This commit is contained in:
jrhrsmit 2021-02-04 13:56:27 +01:00 committed by GitHub
parent ae5056d680
commit e40ca1eb7c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -77,6 +77,9 @@ static int bvd_sample_fetch(const struct device *dev, enum sensor_channel chan)
LOG_DBG("Failed to enable ADC power GPIO: %d", rc);
return rc;
}
// wait for any capacitance to charge up
k_sleep(K_MSEC(10));
}
// Read ADC