Quantcast
Viewing all articles
Browse latest Browse all 5425

General discussion • Re: Detect RPi 5 Best Practices?

Not sure if I should check for "5-model" or "bcm2712". Would the Pi 5 ever NOT be using bcm2712?
I have some software I compile that uses the 3rd party library bcm2835 (for native SPI access) which will not work on the RPi 5 due to the new RP1 southbridge ASIC. I can have my Makefile test for this and not compile in the bcm2835 library (eventually replacing it with spidev in the future).
A pi5 will always use bcm2712.
But bcm2712 could be present on other form factors (e.g. a theoretical Pi500 or CM5).
I'd imagine bcm2712 would usually be what is wanted.
Is /proc/device-tree/compatible the best way to detect 3 or 4 also?
Yes, this scheme also works fine on older pi models.

Statistics: Posted by dom — Fri Jan 05, 2024 10:30 am



Viewing all articles
Browse latest Browse all 5425

Trending Articles