Page 11 of 18

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 9:25 am
by gkreidl
From the official RPi 2 launch statement:
At launch, we are using the same ARMv6 Raspbian userland on both Raspberry Pi 1 and 2; over the next few months we will investigate whether we can obtain higher performance from regular ARMv7 Debian, or whether we can selectively replace a small number of libraries to get the best of both worlds

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 9:58 am
by jamesh
[IDC]Dragon wrote:I have a question about the Pi2 (probably it has been raised elsewhere):

I'm surprised that the existing binaries run on it. Isn't it that the Pi1 with its ARMv6 hard float was a rather unusual beast, requiring a specially compiled distro like Raspian? Well, obviously the Pi2 is somewhat downwards compatible, I wonder how and why.
I noticed the kernel is now split into both ABI flavours. Shoudn't the userland be, too?
Could things run better if the binaries are compiled for the newer ARMv7 architecture, perhaps ordering the instructions for superscalar execution where possible?

Jörg
Userland is mainly shims over GPU calls, so a lot of it will see no benefit from being compiled for A7, there's simply not enough work being done. Some of the demo apps might improve, the raw camera aps for example may have higher performance. But it's all something that will come to light in the next few months.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 1:25 pm
by pico
Has my warranty bit been set on RPi2?

[email protected] ~/tmp $ cat /proc/cpuinfo |grep Rev
Revision : 1a21041

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 1:41 pm
by joan
pico wrote:Has my warranty bit been set on RPi2?

[email protected] ~/tmp $ cat /proc/cpuinfo |grep Rev
Revision : 1a21041
Probably?

May I ask where you bought the Pi 2? It doesn't appear to have been manufactured by Sony.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 1:42 pm
by jdb
pico wrote:Has my warranty bit been set on RPi2?

[email protected] ~/tmp $ cat /proc/cpuinfo |grep Rev
Revision : 1a21041
Can you post your full /boot/config.txt

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:27 pm
by rahlquist
joan wrote:
pico wrote:Has my warranty bit been set on RPi2?

[email protected] ~/tmp $ cat /proc/cpuinfo |grep Rev
Revision : 1a21041
Probably?

May I ask where you bought the Pi 2? It doesn't appear to have been manufactured by Sony.
How can you discern that?

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:35 pm
by joan
My understanding is that the final six hex digits have the following interpretation.

Code: Select all

/proc/cpuinfo revision field

SRRR MMMM PPPP TTTT TTTT VVVV

S scheme (0=old, 1=new)
R RAM (0=256, 1=512, 2=1024)
M manufacturer (0='SONY',1='EGOMAN',2='EMBEST',3='UNKNOWN',4='EMBEST')
P processor (0=2835, 1=2836)
T type (0='A', 1='B', 2='A+', 3='B+', 4='Pi 2 B', 5='Alpha', 6='Compute Module')
V revision (0-15)
Your 1a21041 give a bit pattern of

Code: Select all

1010 0010 0001 0000 0100 0001
SRRR MMMM PPPP TTTT TTTT VVVV

S=1 new scheme
R=2 1024 MB
M=2 EMBEST
P=1 2836
T=4 Pi 2 B
V=1 1

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:37 pm
by pico
From reading elsewhere on the forum, it appears that

force_turbo=1

will set the warranty bit.

Has that always been the case? Or did the criteria change somewhere along the line?

Anyway, here's the config.txt:

Code: Select all

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

# uncomment if hdmi display is not detected and composite is being output
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
#hdmi_group=1
#hdmi_mode=1

# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

#uncomment to overclock the arm. 700 MHz is the default.
arm_freq=840

# for more options see http://elinux.org/RPi_config.txt
gpu_mem=16
core_freq=250
sdram_freq=420
over_voltage=0
force_turbo=1

device_tree=
##dtparam=i2c_arm=on
##dtparam=i2c_vc=on
#dtparam=i2c=on
##dtparam=i2c0=on
##dtparam=i2c1=on
#dtparam=spi=on


Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:40 pm
by pico
joan wrote:My understanding is that the final six hex digits have the following interpretation.

Code: Select all

/proc/cpuinfo revision field

SRRR MMMM PPPP TTTT TTTT VVVV

S scheme (0=old, 1=new)
[/quote]

Thanks for this -- very interesting.

So is the "scheme bit" above the warranty bit, or does it encode something else?

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:42 pm
by ric96
Does the non-PoP arrangement offer better cpu temps?

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:45 pm
by joan
The warranty bit may be encoded in that leading 1 you have. My Pi 2 shows a revision of a01041.

The bit structure was derived from software linked to by gadgetoid (I think).

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 2:48 pm
by mikerr
My pi 2 also shows a01041

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 3:36 pm
by LeBigMacke
Hello,

there is a new option in the overclock menue called "Pi2". In this the standard configuratoin for the Pi2 or what?

Iam confused, please help!
Thanks a lot!

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 3:44 pm
by dom
LeBigMacke wrote: there is a new option in the overclock menue called "Pi2". In this the standard configuratoin for the Pi2 or what?
Yes, as the Pi2 is now 900MHz by default, the lower Pi1 overclocks don't actually make sense, so the Pi2 setting is the most appropriate.
A subsequent update may show a different list depending on whether you are running on Pi1 or Pi2 which may make things clearer.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 5:07 pm
by LeBigMacke
dom wrote: A subsequent update may show a different list depending on whether you are running on Pi1 or Pi2 which may make things clearer.
Thank you for the answer, that would be great!
But when i am using the Pi2 setting my Pi2 freeze when i run one of my own written programs.
The programs are written in Python using OpenCV, Numpy and the V4l2-driver for the Camera Module.
So I'm going to stay in the Medium setting.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 5:24 pm
by tvjon
joan wrote:The warranty bit may be encoded in that leading 1 you have. My Pi 2 shows a revision of a01041.

The bit structure was derived from software linked to by gadgetoid (I think).
I wondered about that too, as I'd inadvertently upgraded a Kodi SD card from a B+ which had a 6 overvolt to RPi2, which has a much less aggressive overvolt, yet my revision still says a01041.

Has your Pi2 arrived yet? I have a small project to use PIGPIO, so I checked github to see if you'd updated it.

Do you have a link to the rev' settings please?

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 6:01 pm
by joan
tvjon wrote:
joan wrote:The warranty bit may be encoded in that leading 1 you have. My Pi 2 shows a revision of a01041.

The bit structure was derived from software linked to by gadgetoid (I think).
I wondered about that too, as I'd inadvertently upgraded a Kodi SD card from a B+ which had a 6 overvolt to RPi2, which has a much less aggressive overvolt, yet my revision still says a01041.

Has your Pi2 arrived yet? I have a small project to use PIGPIO, so I checked github to see if you'd updated it.

Do you have a link to the rev' settings please?
gadgetoid posted earlier at http://www.raspberrypi.org/forums/viewt ... 34#p684334 linking to their Python script at https://github.com/pimoroni/RPi.version. I'm not sure of the original source of the information.

I now have a Pi 2 and have made limited progress with pigpio. See http://www.raspberrypi.org/forums/viewt ... 31&t=98955

It works once successfully initialised but I have to do strange things to get it to initialise. I think I'm running into the same problems I originally had in getting userland DMA working, i.e. ensuring consistency between the DMA and user view of memory (cache coherency). There are a few other oddities which I can not explain but seem to be nothing to do with DMA.

If you want I can host a work in progress version of pigpio that you can play with.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 6:07 pm
by tvjon
joan wrote:...
If you want I can host a work in progress version of pigpio that you can play with.
Yes please.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 6:24 pm
by joan
tvjon wrote:
joan wrote:...
If you want I can host a work in progress version of pigpio that you can play with.
Yes please.
Link now removed.

If you can, access the library through the pigpio daemon rather than linking the library with your own code. Don't ask me why it is more reliable, it just is.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 8:11 pm
by dom
mpnico wrote:I thought that force_turbo with no over_voltage doesn't void the warranty. Is this not correct for the RPi2 ?
You are correct, but Pi2 runs at a higher voltage by default which meant that force_turbo was incorrectly setting the "warranty" bit. That was unintended.

So, what we've agreed to do is to no longer treat bit 24 of the board revision as the warranty warranty bit on Pi 2.
The latest rpi-update will now set bit 25 when a real warranty condition arises (e.g. force_turbo=1 *and* over_voltage > 0)

If bit 24 is currently set, then don't worry, it will be ignored. Bit 25 is the new Pi 2 warranty bit.

Pi1 will remain as it did with bit 24 being the warranty bit.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 8:22 pm
by mpnico
dom wrote:
mpnico wrote:I thought that force_turbo with no over_voltage doesn't void the warranty. Is this not correct for the RPi2 ?
You are correct, but Pi2 runs at a higher voltage by default which meant that force_turbo was incorrectly setting the "warranty" bit. That was unintended.

So, what we've agreed to do is to no longer treat bit 24 of the board revision as the warranty warranty bit on Pi 2.
The latest rpi-update will now set bit 25 when a real warranty condition arises (e.g. force_turbo=1 *and* over_voltage > 0)

If bit 24 is currently set, then don't worry, it will be ignored. Bit 25 is the new Pi 2 warranty bit.

Pi1 will remain as it did with bit 24 being the warranty bit.
Thank you for answering me, I was really surprised seeing the warranty bit set on mine. I hope my post will be usefull for other people.

PS : really good job with this Pi 2 !

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 8:22 pm
by davidcoton
Is there still a potential problem with cards being moved between Pi1 and Pi2 when overclocking is set? Surely some conditions that are not warranty breakers on one, will break it on the other? Most likely where the more tolerant version (whichever that is) has been set to just below the level where the bit sets, and the card is transferred to the other version.

Possible solution: keep the overclock settings separate for Pi1 and Pi2, so that transferring to a different version will not activate the wrong set of settings :?

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 8:43 pm
by dom
davidcoton wrote:Is there still a potential problem with cards being moved between Pi1 and Pi2 when overclocking is set? Surely some conditions that are not warranty breakers on one, will break it on the other?
No, I believe anything that sets warranty bit on Pi1 will set it on Pi2 and vice-versa.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sat Feb 07, 2015 11:38 pm
by rahlquist
ric96 wrote:Does the non-PoP arrangement offer better cpu temps?
I am finding things appear to run about 10deg higher.

CPU Temp: 45.4ºC
GPU Temp: 45.5ºC

The increase could be a change in sensor location? Not sure.

Re: The Raspberry Pi 2 Q&A thread

Posted: Sun Feb 08, 2015 1:25 am
by pico
dom wrote: You are correct, but Pi2 runs at a higher voltage by default which meant that force_turbo was incorrectly setting the "warranty" bit. That was unintended.

So, what we've agreed to do is to no longer treat bit 24 of the board revision as the warranty warranty bit on Pi 2.
The latest rpi-update will now set bit 25 when a real warranty condition arises (e.g. force_turbo=1 *and* over_voltage > 0)

If bit 24 is currently set, then don't worry, it will be ignored. Bit 25 is the new Pi 2 warranty bit.

Pi1 will remain as it did with bit 24 being the warranty bit.
Thanks for the clarification on this. I was confused about what appeared to be the warranty bit appearing on the Pi2 when I hadn't seen this occur on my model Bs.

I have one further question. I want to have a card image that will boot and work on either a model B or a Pi2. i have an image that I've been working on that has the following config.txt:

Code: Select all

#uncomment to overclock the arm. 700 MHz is the default.
arm_freq=840

# for more options see http://elinux.org/RPi_config.txt
gpu_mem=16
core_freq=250
sdram_freq=420
over_voltage=0
force_turbo=1

device_tree=


Will this have any other unexpected consequences, apart from setting bit 24 on the Pi2 (as discussed)? Will the arm_freq of 840 simply be ignored by the Pi2, for example, and it will continue to run at the default 900MHz?

Also, i've discovered that loading the peripheral modules for spi etc using the device tree is not equivalent to loading the old way... the drivers loaded using device tree seem to lead to some performance issues compared to the old drivers. Haven't investigated closely enough to figure out what is happening, but the take home is that the device_tree drivers may not perform as expected when compared to the no device-tree drivers. So in the meantime i've simply disabled the device_tree loading.