Skip to content
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
title: "Calibrate the internal temperature sensor on an Arduino device"
id: 4411202645778
---

When using devices with internal temperature sensors, such as the Arduino Nicla Sense ME or the Arduino MKR IoT Carrier, a common issue is inaccurate temperature readings due to self-heating. This happens because heat generated by other components on the device can affect the sensor, leading to higher readings than the actual ambient temperature. Factors like power supply, board positioning, and the specific code running on the device can increase the impact of this effect.

Calibrating the internal sensor can correct these inaccuracies, giving you more accurate temperature readings.

## Steps to calibrate the temperature sensor

### Measure the required offset

1. Turn on your board and let it operate for some time to allow the components to reach their normal operating temperature, ensuring any heat-related offset becomes noticeable.

1. Use a reliable external source to measure the room temperature, like a digital thermostat.

1. Compare the temperature reading from your sensor with the reading from the external source.

1. Subtract the sensor's reading from the external source's reading to calculate the offset.

### Implement the offset in your sketch

Once you have determined the offset, you can adjust the temperature readings in your sketch. Locate the part of the code that retrieves the temperature value and subtract the offset. For example:

```
float temperature = sensor.readTemperature(); // Function to get temperature from the sensor

float offset = 5; // Your calculated offset

float calibratedTemperature = temperature - offset; // Apply the offset
```

This file was deleted.

Loading