| Electronic Components Datasheet Search |
|
AN1798 Datasheet(PDF) 9 Page - STMicroelectronics |
|
|
|||||||||||||||||||||||||||||
AN1798 Datasheet(HTML) 9 Page - STMicroelectronics |
|
9 / 16 page ![]() AN1798 Calibration and linearization technique 9/16 3.3 Firmware description The calibration, the linearization and offset compensation are done by software. As described in Section 3.1, the ADC conversation range, the gain and the quantum are computed. Figure 6 shows an example flowchart of the software: Figure 6. Calibration firmware implementation Configure ADC inputs to high impedance analog inputs Configure the prescaler Configure the conversion mode: Single Start the conversion Compute the average of the converted value: 2.5V (ADC_MAX) Compute the average of the converted value: 0V (ADC_Min) Start of calibration Select Channel 3 Get the conversion: Calibrated_Result_Data = End of Calibration Compute the unsigned value of Conversion_Result: Select ADC Channel 1 Select ADC Channel 0 Compute the unsigned value of 2.5V: Unsigned_MAX Compute the unsigned value of 0V: Unsigned_Min Compute the sweep of conversion Compute the quantum q Start of conversion polling on Channel 3 Unsigned_Result - Unsigned_Min q = 2.5V/sweep sweep = Unsigned_MAX - Unsigned_Min Calibration section Get calibrated conversion results section Calibrated_Result_Volt = Calibrated_Result_Data * q Conversion_Result Unsigned_Result Note: The delivered software and flowcharts are compatible with the following hardware configuration: Channel_0 to read the ground value Channel_1 to read the 2.5 V value Channel_3 to convert the signal You can modify the hardware configuration but then you have to change also the software to be in line with your hardware. Please refer to Figure 5. |
|
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |