Move ADC_TO_RES macro to header file
This commit is contained in:
parent
cb3c989683
commit
a68b9176cb
@ -94,6 +94,11 @@
|
|||||||
*/
|
*/
|
||||||
#define ADC_PT1000_WATCHDOG_SAMPLE_COUNT 25U
|
#define ADC_PT1000_WATCHDOG_SAMPLE_COUNT 25U
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Conversion macro: ADC value to resistance
|
||||||
|
*/
|
||||||
|
#define ADC_TO_RES(adc) ((float)(adc) / 4096.0f * 2500.0f)
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief This function sets up the ADC measurement fo the external PT1000 temperature sensor
|
* @brief This function sets up the ADC measurement fo the external PT1000 temperature sensor
|
||||||
*
|
*
|
||||||
@ -160,6 +165,16 @@ int adc_pt1000_get_current_resistance(float *resistance);
|
|||||||
*/
|
*/
|
||||||
int adc_pt1000_stream_raw_value_to_memory(volatile float *adc_array, uint32_t length, volatile int *flag_to_set);
|
int adc_pt1000_stream_raw_value_to_memory(volatile float *adc_array, uint32_t length, volatile int *flag_to_set);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief Convert an array of raw adc values to resistance values
|
||||||
|
*
|
||||||
|
* In case \p resistance_dest is NULL, the conversion is done inplace in the
|
||||||
|
* \p raw_source array.
|
||||||
|
*
|
||||||
|
* @param resistance_dest Destination. Maybe NULL.
|
||||||
|
* @param raw_source Source array
|
||||||
|
* @param count Number of values to convert
|
||||||
|
*/
|
||||||
void adc_pt1000_convert_raw_value_array_to_resistance(float *resistance_dest, float *raw_source, uint32_t count);
|
void adc_pt1000_convert_raw_value_array_to_resistance(float *resistance_dest, float *raw_source, uint32_t count);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
Loading…
Reference in New Issue
Block a user