7#define preamplifier_scrivi_il_trimmer 1
8#define preamplifier_leggi_il_trimmer 0
10#define preamplifier_coarse_step_trimmer_default 230e3
11#define preamplifier_fine_step_trimmer_default 1970
13#define preamplifier_positive_saturation 9e6
14#define preamplifier_negative_saturation -9e6
18extern volatile uint16_t preamplifier_attesa_tra_le_misure ;
20extern int32_t preamplifier_error_voltage;
22extern uint8_t preamplifier_canali_da_regolare;
24extern uint8_t preamplifier_externalADC_1_onboardADC_0 ;
25extern uint8_t preamplifier_SAR_1_no_SAR_0;
26extern uint8_t preamplifier_fastSAR_1_no_fastSAR_0;
28extern volatile uint8_t termalizzazione_fatta[];
31 uint8_t starting_value;
32 uint8_t starting_value_neg;
33 uint8_t starting_exp_value[2];
34} preamplifier_SAR_ini[];
37extern int32_t preamplifier_coarse_step_trimmer[];
38extern int32_t preamplifier_fine_step_trimmer[];
40extern uint8_t preamplifier_canali_da_regolare_old;
41extern volatile int32_t preamplifier_Output_offset_target_at_the_moment[] ;
45static void preamplifier_normalize_gain_offset_error(uint8_t scheda_su_scheda_giu_);
53 uint8_t valore_previsto_trimmer_offset, uint8_t solo_recupero_default_comp_se_1);
void instr_preamplifier_scrittura_lettura_trimmer_offset_function(void)
Content of the preamplifier trimmers can be read/write.
void preamplifier_trova_il_guess(uint8_t trimmer_da_usare)
void instr_output_offset_to_be_set_function(void)
The detector bias will be set at the value set with the function instr_detector_Vbias_we_want_to_set_...
void preamplifier_ritorno_al_gain_originale(uint8_t scalata, uint8_t indice_trimmer, uint8_t *target_raggiunto_1_non_raggiunto_0)
This function sets the original gain when a few LSb have to be determined. The umber of bits is bit_t...
void instr_ouput_offset_we_want_to_set_function(void)
The preamplifier offset will be set at the value passed from the CAN with this function if,...
void preamplifier_determina_trimmer_therma_comp(uint8_t scheda_su_scheda_giu, uint8_t canale, uint8_t valore_previsto_trimmer_offset, uint8_t solo_recupero_default_comp_se_1)
This function determines and set the thermal compensation trimmer.
int32_t preamplifier_Output_offset_target[12]
Offset target values.
void preamplifier_aggiusta_offset_SAR(void)
This function provide the output offset with the standard SAR method.
int32_t preamplifier_ADC_external_measured_node_function(uint8_t scheda_su_scheda_giu, uint8_t indice)
This function provide node reading from an external ADC.