Browse Source

board_hw_rev_ve:Use 97.50% for ADC ref for "High" detection

v1.13.0-BW
David Sidrane 3 years ago committed by Daniel Agar
parent
commit
1a17e9df4d
  1. 2
      platforms/nuttx/src/px4/stm/stm32_common/board_hw_info/board_hw_rev_ver.c

2
platforms/nuttx/src/px4/stm/stm32_common/board_hw_info/board_hw_rev_ver.c

@ -313,7 +313,7 @@ static int read_id_dn(int *id, uint32_t gpio_drive, uint32_t gpio_sense, int adc @@ -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;
}
if ((high > low) && high > px4_arch_adc_dn_fullcount() - 100) {
if ((high > low) && high > ((px4_arch_adc_dn_fullcount() * 975) / 1000)) {
*id = low;
rv = OK;

Loading…
Cancel
Save