Điện, điện tử - Chapter 8: Analog - To - digital converter

Built-in voltage reference: Two selectable voltage levels, 2.5V and 1.5V • Setting REFON in ADC10CTL0 register to 1 enables the internal reference • Setting REF2_5V in ADC10CTL0 to 1 selects 2.5 V as the internal reference, otherwise 1.5V • After voltage reference is turned on, we must wait about 30µs for it to settle

pdf21 trang | Chia sẻ: huyhoang44 | Ngày: 23/03/2020 | Lượt xem: 5 | Lượt tải: 0download
Bạn đang xem trước 20 trang tài liệu Điện, điện tử - Chapter 8: Analog - To - digital converter, để xem tài liệu hoàn chỉnh bạn click vào nút DOWNLOAD ở trên
Chapter 8 Analog-to-Digital Converter 8.1 Introduction Microcomputer principles and applications To transform an analog signal into a digital one, the analog-to-digital converter (ADC) samples the input at fixed interval and do the conversion 8.1 Introduction Microcomputer principles and applications 8.1 Introduction Microcomputer principles and applications MSP430 may contain one or more converters: • Comparator: Compare the voltages on its two input terminals and return 0 or 1, e.g., Comparator_A+ • Successive-approximation ADC: Use binary search to determine the closest digital representation of the input signal, e.g., ADC10 and ADC12 to give 10 and 12 bits of output • Sigma-delta ADC: A more complicated ADC that gives higher resolution (more bits) but at a slower speed, e.g., SD16 and SD16_A, both of which give a 16-bit output 8.1 Introduction Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL0 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL0 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL0 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL1 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL1 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10CTL1 Microcomputer principles and applications 8.2 ADC10 Control Registers - ADC10AE0 Microcomputer principles and applications Analog (Input) Enable Control Register 0 8.2 ADC10 Control Registers - ADC10AE1 Microcomputer principles and applications Analog (Input) Enable Control Register 1 8.2 ADC10 Control Registers - ADC10MEM Microcomputer principles and applications Conversion-Memory Register, Binary Format 8.2 ADC10 Control Registers - ADC10MEM Microcomputer principles and applications Conversion-Memory Register, 2s Complement Format 8.2 ADC10 Control Registers - ADC10DTC0 Microcomputer principles and applications Data Transfer Control Register 0 8.2 ADC10 Control Registers - ADC10DTC1 Microcomputer principles and applications Data Transfer Control Register 1 8.2 ADC10 Control Registers - ADC10SA Microcomputer principles and applications Start Address Register for Data Transfer 8.3 Main components of ADC10 Microcomputer principles and applications • Built-in voltage reference: Two selectable voltage levels, 2.5V and 1.5V • Setting REFON in ADC10CTL0 register to 1 enables the internal reference • Setting REF2_5V in ADC10CTL0 to 1 selects 2.5 V as the internal reference, otherwise 1.5V • After voltage reference is turned on, we must wait about 30µs for it to settle 8.4 Steps for single conversion Microcomputer principles and applications • Configure ADC10, including the ADC10ON bit to enable the module. The ENC bit must be clear so that most bits in ADC10CTL0 and ADC10CTL1 can be changed. • Set the ENC bit to enable a conversion. This cannot be done while the module is being configured in the previous step. • Trigger the conversion.This is done either by setting the ADC10SC bit or by an edge from Timer_A. • ADC10ON, ENC, ADC10SC are all in control register ADC10CTL0. 8.5 ADC10 Interrupts Microcomputer principles and applications One interrupt and one interrupt vector: • When DTC is not used (ADC10DTC1 = 0), ADC10IFG is set when conversion results are loaded into ADC10MEM. • When DTC is used (ADC10DTC1 > 0), ADC10IFG is set when a block transfer completes If both ADC10IE and GIE bits are set: • ADC10IFG generates an interrupt request. • ADC10IFG is automatically reset when interrupt request is serviced, or it may be reset by software.

Các file đính kèm theo tài liệu này:

  • pdfchapter_08_analog_to_digital_converter_2182.pdf
Tài liệu liên quan