I’m continuing to maintain & expand this. For example, U-Boot has been building for the 5A as well for a while now. I pre-ordered, so once I get my voucher + board, I’ll actually test this ![]()
Two bigger additions are builds & images for the Rockchip NPU (for ML) libraries and Rockchip MPP (for accelerated video encoding/decoding).
rknpu
The NPU builds are a bit more experimental. I believe everything is working, but I haven’t been able to get the benchmark with YOLOv8s running yet.
If you’re interested, however, take a look here:
rkmpp
The MPP builds I’ve been able to use a bit more extensively: I’ve successfully captured HDMI-IN @ 4k60, encoded it as H264, and streamed it with RTMP from within a container.
tl;dr
Ubuntu base images with everything needed for hardware accelerated encoding/decoding now on Docker Hub: https://hub.docker.com/r/milas/rkmpp-ubuntu
docker run --rm -it --privileged docker.io/milas/rkmpp-ubuntu:22.04
(Or :20.04 for Focal.)
Example: HDMI-IN @ 4k60 → h264 RTMP Stream [Docker]
- Launch mediamtx on the Rock 5
When you’re done, hitdocker run --rm -it --network=host aler9/rtsp-simple-serverCtrl-Cto kill it. - Run a container and stream to the server:
Note that the audio track will be silent in this example.docker run --pull=always --rm -it --privileged --network=host milas/rkmpp-ubuntu:22.04 \ gst-launch-1.0 v4l2src device=/dev/video0 io-mode=dmabuf \ ! video/x-raw,format=NV12,width=3840,height=2160,framerate=60/1 \ ! mpph264enc \ ! h264parse \ ! mux. audiotestsrc wave=silence \ ! voaacenc bitrate=128000 \ ! aacparse \ ! mux. flvmux streamable=true name=mux \ ! queue \ ! rtmpsink location=rtmp://127.0.0.1:1935/mystream
You’ll need to adjust things if your input is not 4k60.
Alternatively, replacev4l2src device=/dev/video0 io-mode=dmabufwithvideotestsrc is-live=trueto send the Gstreamer test stream, which has some colored lines and live static. - Open
http://127.0.0.1:8888/mystreamon the Rock 5 to view the stream or replace127.0.0.1with your Rock 5’s LAN IP. (Refer to mediamtx docs for more possibilities.)
This thread is also a good resource about Gstreamer & RTSP/RTMP with some Rock 5 specific bits:
More info about the available builds/targets is at rock5-toolchain/rkmpp/README.md at main · milas/rock5-toolchain · GitHub.
DISCLAIMER: I work for Docker Inc but this is a personal side-project.