Page 1 of 3

Raspberry Pi 4

Posted: Mon Jun 24, 2019 6:36 pm
by bzt
Hi Guys,

This is so cool https://www.raspberrypi.org/blog/raspbe ... w-from-35/
It looks like almost all my wishes come true :-) ARMv8a (note the "a"), 4G RAM, super fast USB3, PCIe, and finally the legacy VC dropped, and Raspbian switched to Mesa! It is time for me to finally start playing with 3D on Rpi!

The page says that new RPi is not BCM283x any more, as it's built around the BCM2711 SoC. We even got a preliminary data sheet https://github.com/raspberrypi/document ... pi/bcm2711. This is awesome, but is there any news when can we put our hands on a full peripheral documentation? I'm really interested!!! Are there many differences? Or does BCM2711 affect mostly the production line with 28nm, and the API and MMIOs mostly remained the same as in BCM2837? What about the QA7 MMIO which was specific to the BCM2836-7? This is so exciting, like the fist day at school :-D

I think the RPi team well deserve a "well done, excellent work"!
bzt

Re: Raspberry Pi 4

Posted: Mon Jun 24, 2019 7:55 pm
by okenido
I'm also interested into this... super excited by this new raspberry, but I have already my product developed in bare metal around the RPI 3, wondering how hard it would be to support the new SoC.
I guess the ARM core isn't that much different but I'm more worried about the peripherals.

Re: Raspberry Pi 4

Posted: Mon Jun 24, 2019 9:33 pm
by timanu90
My hopes are very high. I didn't had a chance to look into linux code, but I saw a comment from a guy on internet stating that the main interrupt controller is now a standard gic-400 rather than their own thing.

This was my wish :D

Re: Raspberry Pi 4

Posted: Tue Jun 25, 2019 12:51 am
by StevoD
bzt wrote:
Mon Jun 24, 2019 6:36 pm
and finally the legacy VC dropped, and Raspbian switched to Mesa! It is time for me to finally start playing with 3D on Rpi!
Why exactly would you wish for that, you just got locked in to Linux. It had already been shown that bare metal opengl using the VC4 was a reality and now the only way to do real hardware accellerated graphics (not just some stupid triangle example) will be by trying to make the huge Mesa3D thing and all of its DRM and so on compile and run in bare metal.

Re: Raspberry Pi 4

Posted: Tue Jun 25, 2019 10:05 am
by LdB
Hey apparently I know nothing but I find it an interesting concept that you will be locked to Linux, on a board that full Windows 10 runs on and Microsoft will do a Direct3D driver and shaders. They tried doing it for the Videocore IV but it was to dorked for them to support. Personally all I will do is follow there code in it is unlikely I will even look at the linux code ... but hey I love doing it wrong.

Re: Raspberry Pi 4

Posted: Tue Jun 25, 2019 10:44 am
by gothicknight
I'm expecting to receive my rpi4 today so I can start porting my baremetal RTOS into it. Its going to be fun :D

Re: Raspberry Pi 4

Posted: Tue Jun 25, 2019 12:12 pm
by LdB
Hehe enjoy mines a day or 2 away .. good luck and post us trials and tribulations.

Re: Raspberry Pi 4

Posted: Tue Jun 25, 2019 2:25 pm
by bzt
Hi All,

@okenido: I'm very curious if A72 supports the atomic operations, like LDSET for example and the other extensions, like SHA, AES etc. I'm waiting for those so that my bootloader can boot encrypted initrds with decent speed.

@timanu90: really? I've missed that info. That sounds great, I can finally write interrupt controller code that would work on many ARM boards! One big plus and thank you for the RPi engineers!

@StevoD: but Mesa is much more Open Source, is a much more widespread standard, and I can port the VC VI Linux driver instead of messing around with RPi specific code and proprietary binary blobs (I know we haven't get rid of those entirely). It was always my plan to port Mesa to my bare metal app, but I didn't wanted to implement special code for the RPi as I did with the interrupt controller. But you're right, if portability is not an issue, then Mesa just complicates things.

@LdB: :-D

I admit I'm jealous of you guys... Here in my country you can't buy it yet. There are many ads of course, but when you click on them and go to the official reseller's webshop, RPi3B+ is the newest model to choose. :-( Hopefully in a week I can order too!

Cheers,
bzt

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 12:04 am
by Ultibo
bzt wrote:
Tue Jun 25, 2019 2:25 pm
Here in my country you can't buy it yet. There are many ads of course, but when you click on them and go to the official reseller's webshop, RPi3B+ is the newest model to choose. :-( Hopefully in a week I can order too!
There seems to be a fairly long delay in Australia too, major suppliers are quoting September for availability of the 2GB and 4GB models.

We're waiting on a 1GB version that we ordered from one of the few suppliers who had them "in stock" on release day but there is no indication of when it will ship as yet.

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 1:44 am
by lpoulain
@bzt, @LdB,

If that is OK with you, I would like to buy a RPi 4 for each of you. Not only both of you have great Rapsberry Pi tutorials on GitHub, but you seem to be two of the most prolific contributors on this forum.

If you have a PayPal account I can send you the money (if you promise to use it to buy a RPi 4 ;-) )

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 2:25 am
by Gavinmc42
For the Ozzies, these guys have not let me down, still some in stock?
Mine has shipped and should show up tomorrow :D
https://core-electronics.com.au/raspber ... b-1gb.html
I am not connected to them except as a happy customer.

4B1 is good enough for learning baremetal?
Hopefully by the time the next(first) batch of the 4B4's gets downunder, we can have some results.

Eben made a comment of two screens, two mice, two keyboards.
Trying to get my head around doing that in baremetal.
A 4B4 as development box with two of everything should speed up coding.

Edit - wow just made it cheaper for schools, two kids, one Pi :o
Will there be fights over the GPIO pins :lol:

Edit 2- it showed up today, so leaving early, it is calling me. :D

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 4:44 am
by LdB
lpoulain wrote:
Wed Jun 26, 2019 1:44 am
@bzt, @LdB,

If that is OK with you, I would like to buy a RPi 4 for each of you. Not only both of you have great Rapsberry Pi tutorials on GitHub, but you seem to be two of the most prolific contributors on this forum.

If you have a PayPal account I can send you the money (if you promise to use it to buy a RPi 4 ;-) )
Haha thanks for offer but I get mine for free anyhow ... work pays for my toys.

I am time poor at the moment I am playing around with a NanoPi Fire3 getting it blinking etc
The only plus from that is from what has been said the Pi4 loader sounds similar

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 8:40 am
by okenido
Dunno why in 2019 GPU drivers/programming is still such a pain in the ass.
Libraries are huge. APIs are overcomplicated.
Drawing a simple 2D line is ridiculously hard if you want proper hardware acceleration... or rely on libraries like OpenVG but it seems quite slow from my experiments.

I dream of some easy to use, accelerated 2D renderer. Batched rectangles/shapes/bitmap drawing and that's it...

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 9:43 am
by Gavinmc42
Dunno why in 2019 GPU drivers/programming is still such a pain in the ass.
Libraries are huge. APIs are overcomplicated.
Drawing a simple 2D line is ridiculously hard if you want proper hardware acceleration... or rely on libraries like OpenVG but it seems quite slow from my experiments.

I dream of some easy to use, accelerated 2D renderer. Batched rectangles/shapes/bitmap drawing and that's it...
Kind of have to agree with you about the bloat, but there are other ways sneaking through.
Looking forward to trying this on the Pi4
https://ultibo.org/forum/viewtopic.php?f=9&t=1269
Have a look at AJ Starks OpenVG github, I got this to work with his GO code too..

With the faster Pi4 I will probably get sloppy and use some slow library that is now fast enough?
Will be interesting with the Pi4 and two screens, developing on one, running on the other.
That should speed up the process.

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 10:02 am
by bzt
lpoulain wrote:
Wed Jun 26, 2019 1:44 am
@bzt, @LdB,

If that is OK with you, I would like to buy a RPi 4 for each of you. Not only both of you have great Rapsberry Pi tutorials on GitHub, but you seem to be two of the most prolific contributors on this forum.

If you have a PayPal account I can send you the money (if you promise to use it to buy a RPi 4 ;-) )
Thanks, that's very kind of you! Unfortunately my PP account has been hacked as part of the scientologiest's "fair game", and I asked PP to block it for good. But thanks anyway, I appreciate your offer!

Cheers,
bzt

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 11:48 am
by lpoulain
bzt wrote:
Wed Jun 26, 2019 10:02 am
Thanks, that's very kind of you! Unfortunately my PP account has been hacked as part of the scientologiest's "fair game", and I asked PP to block it for good. But thanks anyway, I appreciate your offer!

Cheers,
bzt
That's too bad. If you can think of any other way let me know. And if it wasn't obvious, thank you for your help on this forum.

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 3:18 pm
by DavidS
I am looking forward to the peripheral documentation as well. Even if many things are the same, there is going to be some difference in the base address for the peripheral registers, just to allow for the added RAM (and also curious how they map the peripheral registers into a 4GB config running in AARCH32 [as Raspbian does], are we going to have to use the MMU to map them in and out as needed).

Re: Raspberry Pi 4

Posted: Wed Jun 26, 2019 5:59 pm
by gothicknight
CPU and peripherals base addresses can already be obtained from the Linux source files:
> https://github.com/raspberrypi/linux/bl ... pi-4-b.dts
> https://github.com/raspberrypi/linux/bl ... m2838.dtsi

I already have mine with me so so far there are a few changes:
1) Peripheral base address is now moved to 0x7E000000
2) There's a mention of ARM's GIC400 @ 0x40041000 but probably is only the distributor since the old CPU interface is still there @ 0x40000000

Next step, make the bootloader to... well, boot.

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 2:05 am
by LdB
Our next problem is we are going to run out of GPIO pins did you see the peripherals 5 uarts, 6 SPI's, 4 I2C :-)

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 4:29 am
by rpdom
LdB wrote:
Thu Jun 27, 2019 2:05 am
Our next problem is we are going to run out of GPIO pins did you see the peripherals 5 uarts, 6 SPI's, 4 I2C :-)
More SPIs and I2Cs mean more port expanders can be connected. We're not going to run out any time soon :)

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 8:49 am
by gothicknight
LdB wrote:
Thu Jun 27, 2019 2:05 am
Our next problem is we are going to run out of GPIO pins did you see the peripherals 5 uarts, 6 SPI's, 4 I2C :-)
This is quite common in embedded devices where the exposed pins serve multiple purposes.

The reason is that chip manufacturers want to provide the maximum number of features the end user may want to have but without all the necessary physical connections (aka. pads) for each so it won't get too big/expensive. So there's a module, usually called IOMUX, where the manufacture attaches each PAD to a multitude of modules ALTernatives (UART, SPI, I2C,... and GPIO) that the user can then select the ALT mode they desire.

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 1:25 pm
by hippy
LdB wrote:
Thu Jun 27, 2019 2:05 am
Our next problem is we are going to run out of GPIO pins did you see the peripherals 5 uarts, 6 SPI's, 4 I2C :-)
The real problem comes when wanting to use things in combinations which just aren't allowed; one can have this or that but not both.

There is perhaps nothing more frustrating than when something would be possible but is not achievable. Some microcontrollers therefore offer the ability to map any pin to any peripheral signal.

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 3:09 pm
by bzt
gothicknight wrote:
Wed Jun 26, 2019 5:59 pm
I already have mine with me so so far there are a few changes:
1) Peripheral base address is now moved to 0x7E000000
2) There's a mention of ARM's GIC400 @ 0x40041000 but probably is only the distributor since the old CPU interface is still there @ 0x40000000
Thanks for sharing, these are very useful info!

Cheers,
bzt

Re: Raspberry Pi 4

Posted: Thu Jun 27, 2019 8:21 pm
by Cacodemon
Excited as well. Just waiting til the new 4 is gonna be available in my country. :mrgreen:

Re: Raspberry Pi 4

Posted: Fri Jun 28, 2019 2:25 am
by lpoulain
I heard that the Pi 4 generates much more heat than the Pi 3. I am curious to hear what people who have used both are saying.