Page 14 of 46

Re: Overclocking

Posted: Mon Sep 10, 2012 8:08 pm
by hojnikb
Oh thats great.Thx for explanation.

Now overvolting on a long run doesn't seem such a bad idea :)

Re: Overclocking

Posted: Mon Sep 10, 2012 8:28 pm
by arm2
"/opt/vc/bin/vcgencmd measure_temp" Presumably this is reading an on chip temperature sensor?
If yes is it on an I2C bus?
If Yes which one and is it LM75 compatible?

Re: Overclocking

Posted: Mon Sep 10, 2012 8:37 pm
by dom
arm2 wrote:"/opt/vc/bin/vcgencmd measure_temp" Presumably this is reading an on chip temperature sensor?
If yes is it on an I2C bus?
If Yes which one and is it LM75 compatible?
No not I2C. Just a memory mapped GPU peripheral.

Re: Overclocking

Posted: Mon Sep 10, 2012 8:54 pm
by arm2
dom wrote:
arm2 wrote:"/opt/vc/bin/vcgencmd measure_temp" Presumably this is reading an on chip temperature sensor?
If yes is it on an I2C bus?
If Yes which one and is it LM75 compatible?
No not I2C. Just a memory mapped GPU peripheral.
Thanks for the info. I see from a Liz tweet that sources to vcgencmd should be released soon, will it have enough info to let RISC OS software to be written? Please!

Re: Overclocking

Posted: Tue Sep 11, 2012 10:34 am
by dom
Some overclocking tweaks last night.

Code: Select all

/opt/vc/bin/vcgencmd measure_volts
volt=1.20V
You can also give a parameter of core (the default if omitted), sdram_p, sdram_i, sdram_c.

You may find that you can reliably run, e.g: arm_freq=1000, core_freq=500, sdram=600, overvoltage=6, individually, but when you enable them all together, you get reboots (rather than hangs).
This is the SMPS current limit kicking in to say the current has reached an unexpectedly high level. Now, the chip wasn't designed for this level of overclock, so that's not surprising.
There is a way of disabling this protection, which may allow you to overclock a bit more:

Code: Select all

current_limit_override=0x5A000020
But this is not recommended. For the sake of science, I've been running with this the last month or so, and nothing has died, however we have done no other testing on the effects of this on chip life.
Note, this will only help if you are currently hitting a reboot failure when overclocking too high.

The overvoltage is now limited to 6 (1.35V) by default. force_turbo=1 will allow that to be increased to 8.
The h264/v3d/isp no longer go to their high level when the ARM frequency is high. It was decided that the arm freq being high doesn't imply the h264/v3d/isp are busy.
If you want to overclock these, you will need the force_turbo=1 option.

Re: Overclocking

Posted: Tue Sep 11, 2012 2:47 pm
by hojnikb
So the current limit was bothering me with my reboots. Good to know.. Will test with 1ghz if that helps :)

Re: Overclocking

Posted: Tue Sep 11, 2012 3:39 pm
by markus3141
What is required to access the temps, frequencies etc.? I've got a user named "zabbix" (only in group "zabbix") that can't read the values, it just says "VCHI initialization failed" while another normal user can read them without sudo..

Code: Select all

# sudo -u zabbix /opt/vc/bin/vcgencmd measure_temp
VCHI initialization failed
I'd like to put temps, frequencies and voltages in my monitoring system.

Markus

Re: Overclocking

Posted: Tue Sep 11, 2012 3:48 pm
by dom
markus3141 wrote:What is required to access the temps, frequencies etc.? I've got a user named "zabbix" (only in group "zabbix") that can't read the values

Code: Select all

pi@raspberrypi:~$ ls -l /dev/vchiq
crw-rw---T 1 root video 252, 0 Jan  1  1970 /dev/vchiq
pi@raspberrypi:~$ groups
pi adm dialout cdrom sudo audio video plugdev games users netdev input
so:

Code: Select all

usermod -a -G video zabbix
might do it.

Re: Overclocking

Posted: Tue Sep 11, 2012 3:59 pm
by markus3141
dom wrote:
markus3141 wrote:What is required to access the temps, frequencies etc.? I've got a user named "zabbix" (only in group "zabbix") that can't read the values

Code: Select all

pi@raspberrypi:~$ ls -l /dev/vchiq
crw-rw---T 1 root video 252, 0 Jan  1  1970 /dev/vchiq
pi@raspberrypi:~$ groups
pi adm dialout cdrom sudo audio video plugdev games users netdev input
so:

Code: Select all

usermod -a -G video zabbix
might do it.
Ah, thanks! Wouldn't have thought of having it to add to group video (well, I should have checked the device permissions...).
Works fine now!

Re: Overclocking

Posted: Tue Sep 11, 2012 7:03 pm
by slabua
Is it vcgencmd or vcgemcmd? I have the latter command, but in the posts I read the former. Was there a type in the repository maybe?

Re: Overclocking

Posted: Tue Sep 11, 2012 8:35 pm
by slabua
slabua wrote:Is it vcgencmd or vcgemcmd? I have the latter command, but in the posts I read the former. Was there a type in the repository maybe?
ls -l /usr/bin/vcgemcmd
lrwxrwxrwx. 1 root root 20 Sep 2 20:19 /usr/bin/vcgemcmd -> /opt/vc/bin/vcgencmd

Re: Overclocking

Posted: Tue Sep 11, 2012 10:37 pm
by Joshyu
Sander wrote:
Joshyu wrote: Does anybody know how to use this line in a python script?
Tested code:

Code: Select all

import os

cmd = '/opt/vc/bin/vcgencmd measure_temp'
line = os.popen(cmd).readline().strip()

if "error" in line:
	print "Error ... is your firmware uptodate? Run rpi-update"
else:
	# line now contains something like: temp=41.2'C
	# to get the temperature, split on =, and then on '

	temp = line.split('=')[1].split("'")[0]
	print temp

Result:

Code: Select all

pi@raspberrypi ~ $ python tempie.py 
41.2
pi@raspberrypi ~ $ 
Does this help?
This worked like a charm!
Thanks to everyone who helped!

Re: Overclocking

Posted: Tue Sep 11, 2012 11:48 pm
by milhouse
I must admit all these different settings and overrides are starting to do my head in! ;-)
dom wrote:You can also reduce the stock settings with:

Code: Select all

arm_freq_min
gpu_freq_min
core_freq_min
sdram_freq_min
over_voltage_min
if you would like to underclock.
With the introduction of these "*_min" properties, I have to wonder if it would make sense to rename the existing overclock properties (eg. arm_freq) to include the "_max" suffix (keeping the existing non-suffix properties as synonyms of *_max, at least temporarily for backward compatibility but marked as deprecated).

Doing so would "balance" the properties as after reading about the *_min properties it seems logical that there should be corresponding *_max equivalents, which don't exist... With consistently named and "paired" properties it would be easier to explain (and understand) that the various clocks will dynamically adjust between their min and max settings, depending on the load etc.

Possibly something to consider before this hits education as the "right" choice would be to have min/max properties and I doubt hackers would be bothered by any change at this time.

Re: Overclocking

Posted: Wed Sep 12, 2012 8:49 am
by arm2
markus3141 wrote: I'd like to put temps, frequencies and voltages in my monitoring system.
Markus
If you are going to release your software could you also include support for an I2C connected 'Case' temperature sensor please?

Re: Overclocking

Posted: Thu Sep 13, 2012 3:59 pm
by burntcustard
I'm running stable at:

over_voltage=6
arm_freq=1100
sdram_freq=450
disable_overscan=1

It won't boot if I turn the sdram_freq up much higher.. I don't really want to sacrifice CPU speed for faster memory, but I imagine I could get it higher without such a high arm_freq. Can anyone give me tips on how I might go about pushing the memory more?

I'm looking forward to playing with the _min values once they get included with Raspbmc, because I'm planning on leaving the Pi on all the time eventually :)

Re: Overclocking

Posted: Thu Sep 13, 2012 10:22 pm
by dom
The tempertaure sensor is now available through a thermal driver.

Code: Select all

cat /sys/class/thermal/thermal_zone0/temp
46002
(in milli-degrees-C)
A cool thing is in LXDE, you can right-click the task bar, add/remove panel items, click add, and temperature monitor, and it shows the temperature on the taskbar! I believe it goes red if you reach 85'C (but I can't do that in this climate).
There is also a CPUFreq widget that shows the current freq when you hover over it (shame it doesn't light up when turbo is on).

Re: Overclocking

Posted: Fri Sep 14, 2012 4:47 pm
by bryanandaimee
My first post. Just got a couple Pi from Element14 in the US. They were in stock and shipped quick. They are version 1 boards with Samsung memory.

Overclocked the first one yesterday.
Cell phone supply, PNY 4 gig card, component video connected.
Got 1150 Mhz at overvolt of 8 stable (playing eat squirels game :)
Got 1200 Mhz at overvolt of 8 booted andworked for a few minutes till it froze, no cooling (yet)

Didn't change any other settings.

This was my first rough test. Have yet to try different power supplies, cooling, different cards etc. No serious testing w/ burn in or resource heavy games. I'll do the same w the other Pi soon and then get serious with the better board.

Haven't had this much fun with a computer since I was a teen back when computers were cool.

Re: Overclocking

Posted: Fri Sep 14, 2012 7:09 pm
by caravela
so if i get this right the cpu freq will go from min to max but what about the other overclock options?
let's say i have the following

Code: Select all

arm_freq=900
core_freq=450
sdram_freq=450
What happens to core_freq and sdram_freq when the cpu governor changes frequency ?
do they fluctuate from stock to the defined value or are they just set to the config value ?

Re: Overclocking

Posted: Fri Sep 14, 2012 8:49 pm
by dom
caravela wrote:so if i get this right the cpu freq will go from min to max but what about the other overclock options?
let's say i have the following

Code: Select all

arm_freq=900
core_freq=450
sdram_freq=450
What happens to core_freq and sdram_freq when the cpu governor changes frequency ?
do they fluctuate from stock to the defined value or are they just set to the config value ?
When idle, arm_freq=700, core_freq=250, sdram_freq=400.
When busy, arm_freq=900, core_freq=450, sdram_freq=450.

Re: Overclocking

Posted: Fri Sep 14, 2012 9:05 pm
by caravela
i see. Thanks

Re: Overclocking

Posted: Sat Sep 15, 2012 8:33 am
by markus3141
arm2 wrote:
markus3141 wrote: I'd like to put temps, frequencies and voltages in my monitoring system.
Markus
If you are going to release your software could you also include support for an I2C connected 'Case' temperature sensor please?
Well, it's not my software, its just a Zabbix instance running on my server. But I plan to release a Zabbix-Template for the Raspberry Pi to monitor voltages, temperature, clocks etc.
In Zabbix you can monitor pretty much anything and it's not too hard to setup.

Re: Overclocking

Posted: Sun Sep 16, 2012 2:54 pm
by Trey
Is it possible to read the value of the the SoC bit that gets flipped after your first overvolt? I have two RPi's and lost track of which one I was using to play around with overvolting.

Re: Overclocking

Posted: Sun Sep 16, 2012 3:24 pm
by dom
Trey wrote:Is it possible to read the value of the the SoC bit that gets flipped after your first overvolt? I have two RPi's and lost track of which one I was using to play around with overvolting.

Code: Select all

cat /proc/cpuinfo
...
Revision        : 1000002
will indicate the "warranty" bit at the top end of board revision. It's Bit 24.

Re: Overclocking

Posted: Sun Sep 16, 2012 11:17 pm
by Tafkas
ohrensessel wrote:To monitor the temperature of my pi I wrote a small script that converts the output of vcgencmd measure_temp to the format of lm_sensors, so that it can be used by the munin sensors_ plugin.
How can I use this script within munin?

Re: Overclocking

Posted: Mon Sep 17, 2012 9:34 am
by kevs3d
Very much enjoying overclocking this little marvel :) thanks to dom for adding the firmware features that keep enabling me to get further! The current limit disable feature allowed me to get stable in quake3 with these settings:
Arm 1000
Core 500
DRam 450
GPU 333
Overvolt 5

Stable in both cpu benchmarks and quake3 so very pleased with that. I'm using a small copper dram heatsink to help cool the soc, generally keeps it in the 55C region for CPU heavy stuff, pure GPU stuff (e.g. pishadertoy) will heat it to 70C though. Great fun!

Kev