summaryrefslogtreecommitdiff
path: root/firmware/target/arm/ipod/adc-ipod.c
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/ipod/adc-ipod.c')
-rw-r--r--firmware/target/arm/ipod/adc-ipod.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/firmware/target/arm/ipod/adc-ipod.c b/firmware/target/arm/ipod/adc-ipod.c
index d351f0ee81..493b98ef74 100644
--- a/firmware/target/arm/ipod/adc-ipod.c
+++ b/firmware/target/arm/ipod/adc-ipod.c
@@ -36,6 +36,7 @@ static struct adc_struct adcdata[NUM_ADC_CHANNELS] IDATA_ATTR;
36 36
37static unsigned short _adc_read(struct adc_struct *adc) 37static unsigned short _adc_read(struct adc_struct *adc)
38{ 38{
39#ifndef IPOD_1G2G
39 if (adc->timeout < current_tick) { 40 if (adc->timeout < current_tick) {
40 unsigned char data[2]; 41 unsigned char data[2];
41 unsigned short value; 42 unsigned short value;
@@ -54,7 +55,9 @@ static unsigned short _adc_read(struct adc_struct *adc)
54 } 55 }
55 adc->data = value; 56 adc->data = value;
56 return value; 57 return value;
57 } else { 58 } else
59#endif
60 {
58 return adc->data; 61 return adc->data;
59 } 62 }
60} 63}