You can access the source code files via this link. in this project
In this project, we will delve into the intricacies of utilizing an STM32 microcontroller alongside the AD8495 K-type thermocouple amplifier. Thermocouples are renowned for their sensitivity, necessitating a robust amplifier with cold-compensation reference. While digital thermocouple amplifiers are readily available, the introduction of an exceptional analog-output amplifier adds versatility to temperature sensing applications
The AD8495 K-type thermocouple amplifier from Analog Devices simplifies temperature sensing with its user-friendly design. Featuring comprehensive documentation on the back of its compact PCB, the AD8495 facilitates effortless integration. Powering the board with 3-18VDC and measuring the output voltage on the OUT pin allows for straightforward conversion of voltage to temperature.
Key Features:
- Works exclusively with K-type thermocouples, ensuring compatibility and accuracy.
- Offers an easy-to-use analog output, streamlining the temperature measurement process.
- Provides a wide temperature range: with 5V power, from -250°C to +750°C output (0 to 5VDC), and with 3.3V power, from -250°C to +410°C output (0 to 3.3VDC), subject to the thermocouple's handling capabilities.
- Flexible Power Options: Seamlessly power the board using either 3.3V or 5V, allowing engineers to tailor the temperature range based on application specifications. This versatility ensures compatibility with a wide range of power sources, enhancing the amplifier's adaptability to diverse operating conditions.
To commence this endeavor, we initiate ADC Independent mode configuration, followed by the setup of ADC conversion in regular mode. Subsequently, we establish UART communication to facilitate the transmission of both ADC readings and system status
Step One:- Open CubeMX & Create New Project Choose The Target MCU STM32F103C6 & Double-Click Its Name
- Go To The Clock Configuration & Set The System Clock To 8MHz
Configuration for the
ADC
Mode:
- In the Categories tab, select the [ADC1, enable IN2]
- In the Parameter settings tab, ADC Settings : Enable Continuous Conversion Mode
- In the Parameter settings tab, ADC_Regular_Conversion Mode: [Enabler Regular Conversion Mode & Number of Conversio : 1 & External Trigger Conversion source : Regular Conversion launched by software & Rank1: channel : 2, sympling Time :1.5 Cycles]
Configuration for the
UART
Mode:
- Enable USART1 Module (Asynchronous Mode)
- Set the USART1 communication parameters (baud rate = 9600, parity=NON, stop bits =1, and word length =8bits)
- Generate The Initialization Code & Open The Project In CubeIDE
- Write The Application Layer Code
- Open Proteus & Create New Project and click next
- Click on Pick Device
- Search for STM32F103C6 & TCK & CONN3 & RES & AD8495 & VSOURCE
- Click on Virtual Instruments Mode then choose VIRTUAL TERMINAL
- Click on Terminal Mode then choose (DEFAULT & POWER &GROUND)
- finally make the circuit below and start the simulation
If you have any questions or suggestions don't hesitate to leave a comment below
Comments
Please log in or sign up to comment.