Raspberry Pi Stack Exchange is a question and answer site for users and developers of hardware and software for Raspberry Pi. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to programmatically monitor the temperature of the BCM2835 SoC?

If so, would it do any good? i.e. would temporarily suspending CPU-intensive processes have any chance to reduce the temperature?

I know that one answer is that it should not matter because air cooling is sufficient. However, this is for a situation where air flow in the enclosure is very limited (and the SoC and ethernet controllers are not necessarily the primary heat sources.)

share|improve this question
Do you know how hot it is getting? (Hot to the touch?) Could you add a small heatsink? Or couple the chip to the enclosure with an external heatsink? – Alex L Jun 16 '12 at 7:59
@Alex, probably, but this question is specifically about monitoring. – finnw Jun 16 '12 at 11:54
Can you tell me why this is important? Your Pi should never get hot enough to damage itself, even with low airflow. – Jivings Jun 16 '12 at 14:40
@Jivings, I just fixed a typo in the question (which might address your comment.) There may be other sources of heat, all in a confined space. – finnw Jun 16 '12 at 14:43
@finnw: Thanks, that makes more sense. – Jivings Jun 16 '12 at 14:43
up vote 47 down vote accepted

The ability to monitor the temperature of the GPU has been added to the firmware.

/opt/vc/bin/vcgencmd measure_temp
share|improve this answer
works! very cool – Scoop Sep 23 '12 at 7:29

You can also type:

cat /sys/class/thermal/thermal_zone0/temp

Output will then be in milligrades!

share|improve this answer
Which, I believe, means celsius = milligrades / 1000, e.g. 40084 milligrades = 40.084 C. – berto Nov 17 '15 at 17:22
That is correct berto! – Christian Nov 18 '15 at 23:09

In addition to gnibbler's answer:

/opt/vc/bin/vcgencmd measure_temp| egrep "[0-9.]{4,}" -o
share|improve this answer

Unfortunately, the BCM2835 does not have a temperature sensor.

The documentation is rather limited (purposefully by Broadcom), however there is no mention of a sensor in the data-sheet.

It would be possible to attach your own sensor via the GPIO that monitors the surrounding air temperature or surface temperature of the chip.

However, unless the device will be operating inside your oven, I feel temperature shouldn't be an issue.

share|improve this answer

Here are some handy sensors that have a logic level to indicate if the temperature is above the setpoint http://raspberrypi.stackexchange.com/a/1206/590. You just need one GPIO to detect if it is getting too hot.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.