216 points · by todsacerdoti · 4y ago · 141 comments
Software ecosystem support is THE killer feature for this class of device. And the RPI has, despite its fundamental shortcomings (needing the proprietary GPU to manage bootup, etc.), the best story in that particular department by so much that it's not even a contest.
Exactly!
On the RPI if I want to watch HBO Max without stuttering, all I do is apt install Chromium in Raspbian Buster, fuck around with a dozen or so startup flags, give up, try Kodi, notice that there's no official plugin, install a conceivably legal plugin from "http://k.slyguy.xyz", unzip it, twiddle some quality settings, and put up with intermittent stuttering that's slightly better than when I started the whole process.
I'm just guessing at the Kodi part[1] since I've only made it to the "give up on Chromium" part so far. Anyway, it's probably less work than what the author describes.
Probably.
A couple of years ago, I could happily use a Pi400 as a streaming box for my TV. Today, it's only good for playing videos off of an external drive with stock Raspbian. This was one big reason why I cancelled my Netflix subscription.
In fairness though, I seriously doubt that other SBCs have better streaming support. Is there a project like OpenWRT for HDMI sticks like Roku, Fire TV, etc?
Then you're probably not in the "embedded" space. You're in the "I want a cheap desktop/laptop" space.
You don't need video to run a gateway. You don't need video to drive a piece of machinery. etc.
Only to be incredibly disappointed once they don't deliver what they're expected by specs alone
Sure.
But if you get almost all the way through watching an entire episode of Barry on your gateway and then it stutters, trust me-- you're going to loudly ask why the hell this gateway won't do the goddamned thing it's supposed to.
Interestingly x86 ChromeOS machines with low memory (4GB) didn't have issues with HW accelerated videos, I wonder whether the ARM ChromeOS machines of that era had issues?
My memories are of Indiana Jones-esque gymnastics after stepping on functionality that should have been solid... but turned out to have either been not implemented or implemented in a known-broken way.
It makes me appreciate how good enterprise, desktop, and server software actually is.
And understand why Apple and Google both put in the approval speed bumps they did for apps.
The minimum quality floor is far lower than you would expect...
I think the only sane use of most niche embedded stuff is if you're building a product for a single use case and have a team. Aiming for general purpose & everything works? Hell no!
This is really a sad state of things and a signal something is fundamentally broken in this class of devices.
And that's how I use all of my SBCs (I just counted I have 7 different SoCs on my various boards and mobile devices). I put on a regular whatever distro on all of them (Arch Linux ARM in my case, but it can be anything. That's the point. The distro doesn't need to "support" my board.) it and I only figure out my own kernel and bootloader builds. Bootloader can be figured out once and forgotten about. Kernel just needs a quick update now and then, if I care. Nothing much harder than a make && make install with some env vars set and a corss-compiler installed on my workstation.
I don't need any special board specific software ecosystem provided by some foundation for normal desktop or server uses. It's already there (any GNU/Linux on ARM distribution must work), and it's generic. If the SoC is so bizarre that it can't just run U-Boot/TF-A/Linux/any distro in rootfs in that order, and requires something custom, including non-standard tools in userspace to control basic things like display output, etc., that may not be worth bothering with, but that's only really a domain of Raspberry Pi, and not common anywhere else.
Some distros provide generic kernel builds and a proper bootloader/device tree already, for many boards. So if someone is not interested in building their own, they don't need to. That may limit the choice of the distro though. But it's just an artificial limit.
If you can find them for a good price on eBay or the likes, it's well worth the convenience over any ARM board if all you want is to run a server - I find it preferable to the Raspberry Pi, and especially other ARM SBC hardware.
Reality: a RPI 4 costing as much as a whole Intel NUC, but slower, without upgradable RAM, without native ports to mass storage (SATA/M.2), and not as reliable.
Didn't even have to think that far to see that SBC computers are a joke^W^W not there yet. Considered buying a NanoPi or a Raspberry CM + some board to build a router, with at least 2 physical Gigabit ports. Tallying up all components (sbc, case, power supply, heat sink, etc.) made the NUC with 4 gigabit ports look a bargain.
I really wanted to go the !x86 route, but...
far from being a fundamental shortcoming, that's entirely inconsequential.
A Raspberry Pi's is by far the easiest way to go, but I've found they have become way too expensive. If anyone is looking at cheap SBC's I suggest you pick one with Linux kernel mainline support. Here is a good place to start: https://linux-sunxi.org/Linux_mainlining_effort
A lot of the newer SBC's aren't supported yet. This means that you will be stuck using the vendor's Linux distribution until support lands in the mainline kernel (which could be never). If you get an older SBC with mainline support, you can run 3rd party distros like Armbian. https://www.armbian.com/
Why isn’t there a market for standalone ARM chips and motherboards like there is for x86?
Even if there is some constraint that prohibits scaling up ARM CPUs (e.g., fab capacity shortage) and thus we need to stick with mobile components, what's stopping someone from selling mobos for mobile chips? If the answer is "mobile chips have to be industrially attached to a board" then why aren't there SBCs that are a drop-in replacement for a PC mobo+x86-chip (or if these exist, why are they so niche)?
Arm, Linux support, native sata interface, gbe for about 40 Euro.
And its a good, reliable company.
Demand exists, supply does not. Why? Idk. Maybe it’s a consequence of bad business decisions at ARM.
Apple has recently shown that ARM chips can be competitive with x86. However, I don’t see why we couldn’t have had that a decade ago. Why did we have to wait for a licensee to take this matter into their own hands? It’s like the business execs at ARM are asleep at the wheel. If I were a shareholder, I’d be wanting some different leadership.
Outside of rpi's which have boatloads of community support, about the only boards that aren't this way are the systemready ES/SR certified ones. There is a IR level too, but its still using DT, meaning that the linux kernel devs will break the machine at random times requiring firmware/DT updates when newer kernels are loaded. The ES/SR bands use UEFI+ACPI and provide a standardized platform that is the same as what one expects of a random pc.
I experimented with a RockPro64 a few years ago before learning this lesson. The hardware sounded wonderful. Unfortunately, there was some kind of conflict between the PCIe slot and the GPU. It was possible to get hardware-accelerated video, or use the PCIe slot for additional SATA slots, but not both at the same time. I spent a fair amount of time trying to dig into it, but never did establish whether the problem was in hardware, the device tree, or the drivers.
The Rock64 runs mainline Linux these days with pretty much everything working except the video decoder.
Even the successor Rockchip SoC, the rk3566, has great mainline support despite only being released last year.
I typically use Arch Linux because it's very barebones, and Arch Linux ARM has a working setup [0] for the Rock64. You do need to write various parts like U-Boot bootloader onto the SD card manually, but everything has been pre-compiled. If you prefer an image that you can directly flash onto an SD card like Raspbian, then maybe you can try Armbian [1].
These should get you a working Linux install rather quickly, bringing you to up to the "sixth circle" as written by the author.
[0] https://archlinuxarm.org/platforms/armv8/rockchip/rock64#ins...
That's fine for the OP! They probably wanted to experiment and tinker, no problems there. But it seems to have given a lot of people in this thread the wrong idea about how well supported these devices are for normal users.
A lot of this will be upstreamed and people will use the info from ops article then fill in a bunch of the gaps.
I'm currently debugging the lima DRM driver for NetBSD.
(Asking for my next home server!)
* Vendor integrates a bunch of IP (Cortex, codecs, GPU), tapes out SoC design.
* Vendor has challenges hiring or retaining excellent software engineering team, because VLSI and hardware are the core competencies that make money, not software.
* Vendor's struggling software engineering team hacks copy-pasted code together until they can produce a board support package against a single Linux kernel version, with no care to upstream. Once the device boots in a single configuration, they ship it.
* Vendor's also struggling documentation team attempt to use sketchy descriptions from engineers to produce documentation. Often, internal interfaces are ignored or not documented since "it works" - only the external interfaces needed to make the chip run are documented.
Now, an OEM buys the SoC and BSP. Sometimes they do some extra work to get the BSP to work with a newer kernel, and sometimes they don't. And if they do, they hack on top of the hacks, so the divergence increases and now there are multiple devicetree versions floating around (as happened with this Rock64 board).
You'd imagine at some point the maintenance costs for the chipmakers themselves as well as the increased interest / adoption rates from customers would tip the economics of all of this firmly towards standardization of this mess. Then again, I may not fully understand the economics here, or how much cheaper the current hacky approach is.
[1]: Looking at you, Rockchip, Amlogic, Mediatek, Unisoc, Allwinner, Broadcom and the list goes on. I hope the Raspberry Pi Foundation + Broadcom can take the opportunity with the Raspberry Pi 5 or something to lead the way, but I'm not optimistic at all.
The big problems are when:
* The DeviceTree is incorrect but works anyway because the peripheral drivers are ignoring it.
* The DeviceTree is correct but the peripheral drivers had to be patched to work.
UEFI doesn't seem to do much here, no?
And even moving to ACPI doesn't really change anything - DeviceTree is just a simplified ACPI really, if the ACPI descriptors and what the peripheral drivers do don't match up, it still doesn't work.
But the booting is just a small part of the mess. For the rest I guess the answer is similar - the default state of things is "not working" and a lot of things have to go right to make things run well.
(How long did it take for RPi to get working hw video decoding OOTB with a distribution other than the board specific one from the SBC provider? Or does it even now?)
The water in this case is Linux.
All I want is a handful of risc CPU cores, a few gb of ram, and a framebuffer device with a good blitter. Something well-documented so I can play with the metal.
I did finally get everything working, and I wrote some documentation to capture it.
https://nixos.wiki/wiki/NixOS_on_ARM/NanoPC-T4
What I learned in the process is that Nix is a great resource to see how to get lots of Arm chipsets to bootstrap with Linux. Specifically, the uboot config file.
https://github.com/NixOS/nixpkgs/blob/master/pkgs/misc/uboot...
By reading that, you can get a good view into what proprietary blobs and tools are necessary to get various boards working. As an added bonus, since Nix is declarative and versioned, weird boards should continue to work for the long haul.
Ironically, once I got the board up and running, I completely lost interest. Turns out the challenge of getting it to work was scratching a particular itch, not actually using it in practice.
I'm happily using it on my RockPro64, although I did need to disable USB initialization to get it to boot on mine[2].
[1]: https://tow-boot.org/devices/index.html [2]: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=973323
I can count platforms with lacking SW support on all my fingers, easily, but RK3399 is not it.
DeviceTree is just a file format, it's not really an alternative to the guarantees that UEFI/ACPI provide.
https://github.com/ARM-software/u-boot/blob/master/doc/READM...
No binary blobs available for the graphic card (actually there was a triple graphic chip boosted from Vivante) and Xorg in newer versions couldn't detect it. If you were running an apt-get upgrade on the official image, the very next boot could made the UI experience broken.
I still have the board but I use it headless for pihole and wireguard, but the whole ARM experience becomes awful when it comes to graphic acceleration and the drivers aren't open source and not maintained anymore.
> On 2017-12-14 Debian Buster (currently 'testing') was tested and running GNOME on Wandboard almost worked right out of the box. (In Buster the GNOME session uses Wayland by default instead of Xorg.) The only change needed was reserving contiguous memory, see the 'cma' section above.
Then there is the piece of flaming crap that is the ASMedia PCI-E SATA card that they sell along with the board on their store. That thing cannot handle 2 SSDs and its not a problem with power delivery. Replacing it with some marvel based cards.
People were saying "it's only this first generation, things are getting better fast" since before arm64.
Just as it did with Itanium.
Just as it did with PowerPC.
Just as it did with MIPS.
Just as it did with Transmeta.
Just as it did with ARM last time ( https://en.wikipedia.org/wiki/Acorn_Archimedes )
The year of replacing the x86 architecture never arrives ...
Frankly, I would probably give Itanium the best odds (Intel + Microsoft behind it), then Alpha (Microsoft behind it).
PCs (partially) solve these problems because the BIOS plays the role of secure firmware and first stage boot loader. Hardware enumeration is solved by having most things be PCI-attached and the bios providing ACPI to enumerate the rest.
RISC-V also doesn't solve SoC documentation access. Most of Arm's CPU documentation is freely available, its all the other stuff SoC vendors bolt on that's hard to get access to. I don't see RISC-V changing that.
USB, WiFi, Bluetooth, GPU, memory/gpu interface, hardware media decoders, .... Most of which is proprietary IP and heavily patent encumbered.
An open RISC chip won't help with that.
I miss the days of standardized I/O ports, BIOS interrupts and memory-mapped devices at published addresses. Now, with ACPI, you practically need to run an entire VM in kernel to figure out what’s connected, and the complexity of drivers makes it very difficult for the hobbyist to interact directly with hardware.
I had a RockPro64 for a while that I had tons of trouble getting to work for almost these exact reasons (largely thanks to uboot). Got rid of my Pinebook Pro for similar reasons.
Pine64 makes tons of interesting devices then relies almost 100% on unpaid post-consumer-hobbyist interest for any usability outside of a hacked together barebones ecosystem. Even their unique PineTime, which has been out for some time, is at a barely functioning level and I have zero hope for the PineNote at this point.
I really wish they cared about more than spinning out flashy hardware and patting themselves on the back.
Doing it yourself is a lot of "fun" and a good learning experience.
On the Rockchip SoC in question, boot security is disabled by default, so you can compile it yourself from source and run your own modified version if you want to.
[1] www.trustedfirmware.org
The patch to the (already mainlined ages ago) device tree is not "on the manufacturer's website" because it is already on the Linux kernel's website. To which I linked. And it will be in Linux kernel 5.19.
Unlike Broadcom's fruit-themed tax evasion scheme, we strive to mainline support for the devices, so that you do not need manufacturer specific patches and mainline Linux just works out of the box.
The berries wrinkle their nose at this approach, as they'd rather use a proprietary boot chain with their own kernel fork and pre-made SD card images containing forks of Debian for maximum handholding.
Meanwhile, I'll be content booting fully open and auditable firmware with mainline bootloaders, kernels and userlands. We all have our own priorities.
You can like it or not but they're pretty open about the business model.
This is exactly why I am not on the hype of ARM for personal computing. It's like every computer with ARM SoC is completely different beast.
There's no support in ffmpeg for v4l2-requests API, and nobody forward ported old Bootlin vaapi wrapper driver around v4l2-requests API to the stabilized public version of the API, yet. So app relying on these programs/interfaces don't get the acceleration, atm.