git.droids-corp.org
/
aversive.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
traj update
[aversive.git]
/
modules
/
hardware
/
adc
/
adc.c
diff --git
a/modules/hardware/adc/adc.c
b/modules/hardware/adc/adc.c
index
a40d730
..
ba0971c
100644
(file)
--- a/
modules/hardware/adc/adc.c
+++ b/
modules/hardware/adc/adc.c
@@
-33,7
+33,7
@@
static void (*adc_event)(int16_t) = NULL;
/**
* Initialisation of ADC internal registers
/**
* Initialisation of ADC internal registers
- * Can be called for a wake up after a shutdown command
+ * Can be called for a wake up after a shutdown command
*/
void adc_init(void)
{
*/
void adc_init(void)
{
@@
-90,7
+90,7
@@
SIGNAL(SIG_ADC)
return;
result = ADC;
return;
result = ADC;
-
+
/* sign extension to fill the 16 bits when negative
* (for the 16 bits output format, the output is
* already right.) */
/* sign extension to fill the 16 bits when negative
* (for the 16 bits output format, the output is
* already right.) */
@@
-98,7
+98,7
@@
SIGNAL(SIG_ADC)
&& !(g_adc_previous_config & ADC_MODE_16_BITS)
&& (result & 0x0200) )
result |= 0xFE00;
&& !(g_adc_previous_config & ADC_MODE_16_BITS)
&& (result & 0x0200) )
result |= 0xFE00;
-
+
adc_event(result);
}
adc_event(result);
}