Jump to content
  • 0

Frequency throttling on OPi PC2?




I've got an Orange Pi PC2, and I'm running some pretty CPU intensive tasks on it.  However, I'm running into a situation where the processor is overheating and shutting down.  I've got a bunch of OPiZero's, and on those I'm used to the kernel automatically throttling the CPU frequency down and/or shutting off cores in response to rising CPU temps -- but I'm not seeing that happen on the PC2 -- it just stays at max CPU speed until it overheats and shuts down.  Is there a way to enable that same behavior on the PC2?  (I'd rather it throttle down the CPU frequency instead of overheat...) 

Edited by mikaey
Link to comment
Share on other sites

4 answers to this question

Recommended Posts

  • 0

There is already some discussion about this topic at the other topic


However, if this is causing you issues that need fixing now, it shouldn't be too hard to work around it manually until a better solution is available


Simplest solution might be to have a script / service running (as root) that does

- read temp from /sys/devices/virtual/thermal/thermal_zone0/temp

- if temp is too high for you, throttle max frequency, e.g. using


cpufreq-set -u 700000

then up the limit again once temp is reduced.


Not ideal of course, but should work in the short term.


How high is your temp getting before shutdown? Or what does


armbianmonitor -m 


output before it shuts down?


Just asking as I have a hard time getting my OPi PC2 above 82C under load, no heatsinks, but no casing either...



Link to comment
Share on other sites

Armbian Linux community supported weekly builds download

  • 0

Ok, I think I got it!  Had to learn a little bit about device trees in the process.  BUT...here's what I did (and BTW -- I did this all directly on the PC2):


Step 1: Grab a copy of the Linux source:

$ sudo apt install linux-source-4.19.20-next-sunxi64

This will dump the Linux source tarballs (and a config file) into /usr/src.


Step 2: Unzip the tarball, and copy in the config file:

$ cd /usr/src
$ sudo mkdir linux
$ sudo chown `whoami`:`whoami` linux
$ cd linux
$ tar xvf ../linux-source-4.19.20-sunxi64.tar.xz
$ xzcat ../linux-sunxi64-next_4.19.20_5.75_config.xz >.config

Step 3: Download the attached patch and apply it:

$ patch -p1 <OrangePiPC2.patch

Step 4: Build the new DTB:

$ make dtbs

You should find your new DTB under arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dtb.


Step 5: Copy the new DTB into your DTBs folder:

$ sudo cp arch/arm64/boot/dts/allwinner/sun50i-h5-orangepi-pc2.dtb /boot/dtb/allwinner

Step 6: Reboot!

$ sudo reboot

The PC2 will now throttle automatically when temps start getting too high!


Link to comment
Share on other sites

This topic is now closed to further replies.

  • Create New...