mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-06-04 05:05:19 +08:00
board_hw_rev_ve:Use 97.50% for ADC ref for "High" detection
This commit is contained in:
committed by
Daniel Agar
parent
ebc8ecdee6
commit
1a17e9df4d
@@ -313,7 +313,7 @@ static int read_id_dn(int *id, uint32_t gpio_drive, uint32_t gpio_sense, int adc
|
|||||||
low = dn_sum / samples;
|
low = dn_sum / samples;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((high > low) && high > px4_arch_adc_dn_fullcount() - 100) {
|
if ((high > low) && high > ((px4_arch_adc_dn_fullcount() * 975) / 1000)) {
|
||||||
|
|
||||||
*id = low;
|
*id = low;
|
||||||
rv = OK;
|
rv = OK;
|
||||||
|
|||||||
Reference in New Issue
Block a user