Fix bug
This commit is contained in:
parent
4f33816f2b
commit
b9a01bcad9
8
firmware/.gitignore
vendored
8
firmware/.gitignore
vendored
@ -1,3 +1,11 @@
|
|||||||
*.elf
|
*.elf
|
||||||
memmap.map
|
memmap.map
|
||||||
obj/
|
obj/
|
||||||
|
*.creator
|
||||||
|
*.user
|
||||||
|
*.user*
|
||||||
|
*.cflags
|
||||||
|
*.cxxflags
|
||||||
|
*.files
|
||||||
|
*.includes
|
||||||
|
*.config
|
||||||
|
@ -54,6 +54,8 @@ int32_t temperature_adc_get_temp(void)
|
|||||||
temp = ((temp_lf_s23_8 / 16) * vdd_lf_s23_8 / FLOAT_TO_S23_8(3.3)) * 16;
|
temp = ((temp_lf_s23_8 / 16) * vdd_lf_s23_8 / FLOAT_TO_S23_8(3.3)) * 16;
|
||||||
temp = (get_temp_sensor_cal() << 10) - temp;
|
temp = (get_temp_sensor_cal() << 10) - temp;
|
||||||
temp = (temp * 10 / slope) + 300;
|
temp = (temp * 10 / slope) + 300;
|
||||||
|
|
||||||
|
return temp;
|
||||||
}
|
}
|
||||||
|
|
||||||
static uint32_t get_vrefint_cal(void)
|
static uint32_t get_vrefint_cal(void)
|
||||||
@ -99,4 +101,4 @@ void DMA_CH1_IRQHandler(void)
|
|||||||
if (isr & DMA_ISR_TCIF1) {
|
if (isr & DMA_ISR_TCIF1) {
|
||||||
process_adc_samples();
|
process_adc_samples();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user