fuze+: add unknown channel to debug menu
imx233: always divide physical channels by two for wider range The Fuze+ OF monitors channel 2 but I'm unable to determine the meaning of it. Print the value on the debug menu so that people can have a look at it. Change-Id: I8a942febeafbce06014178abda12e38a16c26664
This commit is contained in:
parent
9caffa8bf7
commit
e07b22f27e
3 changed files with 5 additions and 2 deletions
|
@ -76,7 +76,7 @@ int adc_read_physical(int src)
|
|||
{
|
||||
int virt = imx233_lradc_acquire_channel(TIMEOUT_BLOCK);
|
||||
// divide by two for wider ranger
|
||||
imx233_lradc_setup_channel(virt, false, false, 0, src);
|
||||
imx233_lradc_setup_channel(virt, true, false, 0, src);
|
||||
int val = adc_read_physical_ex(virt);
|
||||
imx233_lradc_release_channel(virt);
|
||||
return val;
|
||||
|
|
|
@ -27,6 +27,7 @@ int imx233_adc_mapping[] =
|
|||
[ADC_DIE_TEMP] = IMX233_ADC_DIE_TEMP,
|
||||
[ADC_VDDIO] = IMX233_ADC_VDDIO,
|
||||
[ADC_5V] = HW_LRADC_CHANNEL_5V,
|
||||
[ADC_CH2] = HW_LRADC_CHANNEL(2),
|
||||
};
|
||||
|
||||
const char *imx233_adc_channel_name[] =
|
||||
|
@ -35,4 +36,5 @@ const char *imx233_adc_channel_name[] =
|
|||
"Die temperature(°C)",
|
||||
"VddIO",
|
||||
"Vdd5V",
|
||||
"Channel 2",
|
||||
};
|
||||
|
|
|
@ -21,11 +21,12 @@
|
|||
#ifndef _ADC_TARGET_H_
|
||||
#define _ADC_TARGET_H_
|
||||
|
||||
#define NUM_ADC_CHANNELS 4
|
||||
#define NUM_ADC_CHANNELS 5
|
||||
|
||||
#define ADC_BATTERY 0
|
||||
#define ADC_DIE_TEMP 1
|
||||
#define ADC_VDDIO 2
|
||||
#define ADC_5V 3
|
||||
#define ADC_CH2 4
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue