Identifying Raspberry Pi

How to identify your Raspberry Pi, maybe built in a nice and sealed box? Here is how:

$ cat /sys/firmware/devicetree/base/model;echo
Raspberry Pi Model B Rev 2
$
$ cat /sys/firmware/devicetree/base/model;echo
Raspberry Pi 3 Model B Rev 1.2
$
$ cat /sys/firmware/devicetree/base/model;echo
Raspberry Pi 3 Model B Plus Rev 1.3
$
$ cat /sys/firmware/devicetree/base/model;echo
Raspberry Pi 4 Model B Plus Rev 1.5
$

How to get the serial number?

$ cat /sys/firmware/devicetree/base/serial-number;echo
10000000694aab1c
$

1 Comment

Add a Comment
  1. Thanks for that, Markku. Added it to my list. 😉
    I am frequently using the following two commands as well to get the versions of Raspbian and the kernel:
    cat /etc/os-release
    uname -a

    Cheers, Johannes

Leave a Reply