[raspberry pi4]拿到raspberry pi4之后,如何熟悉单板


//基本配置命令
sudo raspi-config
//7zip GUI

pi@raspberrypi:~/Downloads $ ./7zzs b

7-Zip (z) 21.07 (armt) : Copyright (c) 1999-2021 Igor Pavlov : 2021-12-26
 32-bit arm_v:7 thumb:2 locale=zh_CN.UTF-8 Threads:4

Compiler: 9.2.1 20191025 GCC 9.2.1
Linux : 5.10.52-v7l+ : #1441 SMP Tue Aug 3 18:11:56 BST 2021 : armv7l
PageSize:4KB hwcap:3FB0D6:NEON hwcap2:10:CRC32
LE 

1T CPU Freq (MHz):   770  1496  1499  1482  1492  1498  1498
2T CPU Freq (MHz): 199% 1487   200% 1498  

RAM size:    2048 MB,  # CPU hardware threads:   4
RAM usage:    889 MB,  # Benchmark threads:      4

                       Compressing  |                  Decompressing
Dict     Speed Usage    R/U Rating  |      Speed Usage    R/U Rating
         KiB/s     %   MIPS   MIPS  |      KiB/s     %   MIPS   MIPS

22:       4002   333   1170   3894  |      79365   363   1865   6771
23:       3711   339   1116   3781  |      77910   364   1853   6741
24:       3640   342   1144   3914  |      81043   388   1833   7112
25:       3506   351   1142   4004  |      72867   358   1810   6485
----------------------------------  | ------------------------------
Avr:      3715   341   1143   3898  |      77796   368   1840   6777
Tot:             355   1492   5338

console:

RAM size:    2048 MB,  # CPU hardware threads:   4
RAM usage:    889 MB,  # Benchmark threads:      4

                       Compressing  |                  Decompressing
Dict     Speed Usage    R/U Rating  |      Speed Usage    R/U Rating
         KiB/s     %   MIPS   MIPS  |      KiB/s     %   MIPS   MIPS

22:       4159   333   1216   4046  |      80710   362   1901   6886
23:       3981   345   1177   4057  |      82400   378   1887   7130
24:       3753   337   1198   4035  |      76818   360   1875   6741
25:       3684   357   1178   4207  |      74340   358   1849   6616
----------------------------------  | ------------------------------
Avr:      3894   343   1192   4086  |      78567   364   1878   6843
Tot:             354   1535   5465

//系统温度:
cd /sys/class/thermal
ls -al
cat thermal_zone0/type
cat thermal_zone0/temp

查询linux系统的信息

启动脚本:待补充

pi@raspberrypi:~ $ cat /etc/os-release

PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

pi@raspberrypi:~ $ lsmod

Module                  Size  Used by
rfcomm                 49152  4
fuse                  126976  3
bnep                   20480  2
hci_uart               40960  1
btbcm                  16384  1 hci_uart
bluetooth             393216  29 hci_uart,bnep,btbcm,rfcomm
ecdh_generic           16384  1 bluetooth
ecc                    40960  1 ecdh_generic
8021q                  32768  0
garp                   16384  1 8021q
stp                    16384  1 garp
llc                    16384  2 garp,stp
joydev                 20480  0
vc4                   253952  3
brcmfmac              327680  0
cec                    49152  1 vc4
brcmutil               20480  1 brcmfmac
sha256_generic         16384  0
drm_kms_helper        241664  3 vc4
v3d                    73728  3
gpu_sched              45056  1 v3d
cfg80211              761856  1 brcmfmac
drm                   520192  10 v3d,vc4,gpu_sched,drm_kms_helper
rfkill                 32768  6 bluetooth,cfg80211
drm_panel_orientation_quirks    16384  1 drm
bcm2835_codec          36864  0
bcm2835_isp            32768  0
bcm2835_v4l2           40960  0
v4l2_mem2mem           36864  1 bcm2835_codec
raspberrypi_hwmon      16384  0
bcm2835_mmal_vchiq     28672  3 bcm2835_isp,bcm2835_codec,bcm2835_v4l2
videobuf2_dma_contig    20480  2 bcm2835_isp,bcm2835_codec
videobuf2_vmalloc      16384  1 bcm2835_v4l2
videobuf2_memops       16384  2 videobuf2_dma_contig,videobuf2_vmalloc
videobuf2_v4l2         32768  4 bcm2835_isp,bcm2835_codec,bcm2835_v4l2,v4l2_mem2mem
videobuf2_common       61440  5 bcm2835_isp,bcm2835_codec,bcm2835_v4l2,v4l2_mem2mem,videobuf2_v4l2
snd_soc_core          225280  1 vc4
videodev              249856  6 bcm2835_isp,bcm2835_codec,videobuf2_common,bcm2835_v4l2,v4l2_mem2mem,videobuf2_v4l2
snd_compress           20480  1 snd_soc_core
snd_bcm2835            28672  4
mc                     45056  6 bcm2835_isp,bcm2835_codec,videobuf2_common,videodev,v4l2_mem2mem,videobuf2_v4l2
snd_pcm_dmaengine      16384  1 snd_soc_core
vc_sm_cma              32768  2 bcm2835_isp,bcm2835_mmal_vchiq
snd_pcm               106496  5 snd_compress,vc4,snd_pcm_dmaengine,snd_bcm2835,snd_soc_core
snd_timer              32768  1 snd_pcm
snd                    77824  13 snd_compress,snd_timer,snd_bcm2835,snd_soc_core,snd_pcm
syscopyarea            16384  1 drm_kms_helper
sysfillrect            16384  1 drm_kms_helper
sysimgblt              16384  1 drm_kms_helper
fb_sys_fops            16384  1 drm_kms_helper
rpivid_mem             16384  0
backlight              20480  1 drm
uio_pdrv_genirq        16384  0
uio                    20480  1 uio_pdrv_genirq
nvmem_rmem             16384  0
i2c_dev                20480  0
ip_tables              28672  0
x_tables               32768  1 ip_tables
ipv6                  495616  38

pi@raspberrypi:/proc $ cat cpuinfo

processor	: 0
model name	: ARMv7 Processor rev 3 (v7l)
BogoMIPS	: 126.00
Features	: half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xd08
CPU revision	: 3

processor	: 1
model name	: ARMv7 Processor rev 3 (v7l)
BogoMIPS	: 126.00
Features	: half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xd08
CPU revision	: 3

processor	: 2
model name	: ARMv7 Processor rev 3 (v7l)
BogoMIPS	: 126.00
Features	: half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xd08
CPU revision	: 3

processor	: 3
model name	: ARMv7 Processor rev 3 (v7l)
BogoMIPS	: 126.00
Features	: half thumb fastmult vfp edsp neon vfpv3 tls vfpv4 idiva idivt vfpd32 lpae evtstrm crc32 
CPU implementer	: 0x41
CPU architecture: 7
CPU variant	: 0x0
CPU part	: 0xd08
CPU revision	: 3

Hardware	: BCM2711
Revision	: c03111
Serial		: 10000000bafb5028
Model		: Raspberry Pi 4 Model B Rev 1.1

pi@raspberrypi:/proc $ cat meminfo

MemTotal:        3866504 kB
MemFree:         3455744 kB
MemAvailable:    3548456 kB
Buffers:           29196 kB
Cached:           222252 kB
SwapCached:            0 kB
Active:            86360 kB
Inactive:         230344 kB
Active(anon):        540 kB
Inactive(anon):   112308 kB
Active(file):      85820 kB
Inactive(file):   118036 kB
Unevictable:       30248 kB
Mlocked:              16 kB
HighTotal:       3211264 kB
HighFree:        2882908 kB
LowTotal:         655240 kB
LowFree:          572836 kB
SwapTotal:        102396 kB
SwapFree:         102396 kB
Dirty:                 0 kB
Writeback:             0 kB
AnonPages:         95600 kB
Mapped:            97464 kB
Shmem:             47596 kB
KReclaimable:      15648 kB
Slab:              32292 kB
SReclaimable:      15648 kB
SUnreclaim:        16644 kB
KernelStack:        1696 kB
PageTables:         4108 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:     2035648 kB
Committed_AS:     846776 kB
VmallocTotal:     245760 kB
VmallocUsed:        5300 kB
VmallocChunk:          0 kB
Percpu:              464 kB
CmaTotal:         262144 kB
CmaFree:          247876 kB

pi@raspberrypi:/proc $ cat mounts

/dev/root / ext4 rw,noatime 0 0
devtmpfs /dev devtmpfs rw,relatime,size=1801156k,nr_inodes=97762,mode=755 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
proc /proc proc rw,relatime 0 0
securityfs /sys/kernel/security securityfs rw,nosuid,nodev,noexec,relatime 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000 0 0
tmpfs /run tmpfs rw,nosuid,nodev,mode=755 0 0
tmpfs /run/lock tmpfs rw,nosuid,nodev,noexec,relatime,size=5120k 0 0
tmpfs /sys/fs/cgroup tmpfs ro,nosuid,nodev,noexec,mode=755 0 0
cgroup2 /sys/fs/cgroup/unified cgroup2 rw,nosuid,nodev,noexec,relatime,nsdelegate 0 0
cgroup /sys/fs/cgroup/systemd cgroup rw,nosuid,nodev,noexec,relatime,xattr,name=systemd 0 0
none /sys/fs/bpf bpf rw,nosuid,nodev,noexec,relatime,mode=700 0 0
cgroup /sys/fs/cgroup/net_cls,net_prio cgroup rw,nosuid,nodev,noexec,relatime,net_cls,net_prio 0 0
cgroup /sys/fs/cgroup/cpu,cpuacct cgroup rw,nosuid,nodev,noexec,relatime,cpu,cpuacct 0 0
cgroup /sys/fs/cgroup/cpuset cgroup rw,nosuid,nodev,noexec,relatime,cpuset 0 0
cgroup /sys/fs/cgroup/pids cgroup rw,nosuid,nodev,noexec,relatime,pids 0 0
cgroup /sys/fs/cgroup/freezer cgroup rw,nosuid,nodev,noexec,relatime,freezer 0 0
cgroup /sys/fs/cgroup/devices cgroup rw,nosuid,nodev,noexec,relatime,devices 0 0
cgroup /sys/fs/cgroup/blkio cgroup rw,nosuid,nodev,noexec,relatime,blkio 0 0
cgroup /sys/fs/cgroup/perf_event cgroup rw,nosuid,nodev,noexec,relatime,perf_event 0 0
systemd-1 /proc/sys/fs/binfmt_misc autofs rw,relatime,fd=41,pgrp=1,timeout=0,minproto=5,maxproto=5,direct 0 0
mqueue /dev/mqueue mqueue rw,relatime 0 0
debugfs /sys/kernel/debug debugfs rw,relatime 0 0
sunrpc /run/rpc_pipefs rpc_pipefs rw,relatime 0 0
configfs /sys/kernel/config configfs rw,relatime 0 0
/dev/mmcblk0p1 /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,errors=remount-ro 0 0
tmpfs /run/user/1000 tmpfs rw,nosuid,nodev,relatime,size=386648k,mode=700,uid=1000,gid=1000 0 0
gvfsd-fuse /run/user/1000/gvfs fuse.gvfsd-fuse rw,nosuid,nodev,relatime,user_id=1000,group_id=1000 0 0
fusectl /sys/fs/fuse/connections fusectl rw,relatime 0 0

pi@raspberrypi:/proc $ uname -a

Linux raspberrypi 5.10.17-v7l+ #1414 SMP Fri Apr 30 13:20:47 BST 2021 armv7l GNU/Linux

pi@raspberrypi:/proc $ cat cmdline

coherent_pool=1M 8250.nr_uarts=0 snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1 video=HDMI-A-1:1440x900M@60 smsc95xx.macaddr=DC:A6:32:17:19:A2 vc_mem.mem_base=0x3ec00000 vc_mem.mem_size=0x40000000  console=ttyS0,115200 console=tty1 root=PARTUUID=97685b82-02 rootfstype=ext4 elevator=deadline fsck.repair=yes rootwait quiet splash plymouth.ignore-serial-consoles

pi@raspberrypi:/proc $ cat interrupts

CPU0       CPU1       CPU2       CPU3       
 25:          1          0          0          0     GICv2  99 Level     timer
 26:          0          0          0          0     GICv2  29 Level     arch_timer
 27:      17565       7886       8942      10472     GICv2  30 Level     arch_timer
 33:       4824          0          0          0     GICv2  65 Level     fe00b880.mailbox
 36:       6507          0          0          0     GICv2 153 Level     uart-pl011
 39:        347          0          0          0     GICv2 114 Level     DMA IRQ
 46:       2148          0          0          0     GICv2  66 Level     VCHIQ doorbell
 47:      29807          0          0          0     GICv2 158 Level     mmc1, mmc0
 48:      46489          0          0          0     GICv2 144 Level     vc4 firmware kms
 54:       3730          0          0          0     GICv2 189 Level     eth0
 55:          0          0          0          0     GICv2 190 Level     eth0
 61:       7059          0          0          0     GICv2 106 Level     v3d
 62:          0          0          0          0     GICv2 175 Level     PCIe PME
 63:       2364          0          0          0  BRCM STB PCIe MSI 524288 Edge      xhci_hcd
IPI0:          0          0          0          0  CPU wakeup interrupts
IPI1:          0          0          0          0  Timer broadcast interrupts
IPI2:        254        258        277        295  Rescheduling interrupts
IPI3:       9411      11020      18603      13819  Function call interrupts
IPI4:          0          0          0          0  CPU stop interrupts
IPI5:       1805        707        574        817  IRQ work interrupts
IPI6:          0          0          0          0  completion interrupts
Err:          0

pi@raspberrypi:/proc $ cat devices

Character devices:
  1 mem
  4 /dev/vc/0
  4 tty
  5 /dev/tty
  5 /dev/console
  5 /dev/ptmx
  5 ttyprintk
  7 vcs
 10 misc
 13 input
 14 sound
 29 fb
 81 video4linux
 89 i2c
116 alsa
128 ptm
136 pts
162 raw
180 usb
189 usb_device
204 ttyAMA
216 rfcomm
226 drm
236 cec
237 media
238 rpivid-vp9mem
239 rpivid-h264mem
240 rpivid-intcmem
241 rpivid-hevcmem
242 uio
243 vchiq
244 hidraw
245 rpmb
246 bcm2835-gpiomem
247 vcio
248 vc-mem
249 bsg
250 watchdog
251 lirc
252 rtc
253 dma_heap
254 gpiochip

Block devices:
  1 ramdisk
  7 loop
  8 sd
 65 sd
 66 sd
 67 sd
 68 sd
 69 sd
 70 sd
 71 sd
128 sd
129 sd
130 sd
131 sd
132 sd
133 sd
134 sd
135 sd
179 mmc
259 blkext

pi@raspberrypi:/proc $ df -h

\u6587\u4ef6\u7cfb\u7edf        \u5bb9\u91cf  \u5df2\u7528  \u53ef\u7528 \u5df2\u7528% \u6302\u8f7d\u70b9
/dev/root        14G  7.5G  5.8G   57% /
devtmpfs        1.8G     0  1.8G    0% /dev
tmpfs           1.9G     0  1.9G    0% /dev/shm
tmpfs           1.9G   17M  1.9G    1% /run
tmpfs           5.0M  4.0K  5.0M    1% /run/lock
tmpfs           1.9G     0  1.9G    0% /sys/fs/cgroup
/dev/mmcblk0p1  253M   48M  205M   19% /boot
tmpfs           378M  4.0K  378M    1% /run/user/1000

root@raspberrypi:/proc # fdisk -l

Disk /dev/ram0: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram1: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram2: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram3: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram4: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram5: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram6: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram7: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram8: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram9: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram10: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram11: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram12: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram13: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram14: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/ram15: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/mmcblk0: 14.5 GiB, 15523119104 bytes, 30318592 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x97685b82

Device         Boot  Start      End  Sectors  Size Id Type
/dev/mmcblk0p1        8192   532479   524288  256M  c W95 FAT32 (LBA)
/dev/mmcblk0p2      532480 30318591 29786112 14.2G 83 Linux

root@raspberrypi:/usr/bin # lsblk

NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0     179:0    0 14.5G  0 disk 
├─mmcblk0p1 179:1    0  256M  0 part /boot
└─mmcblk0p2 179:2    0 14.2G  0 part /

root@raspberrypi:/proc # cat iomem

00000000-37ffffff : System RAM
  00008000-00ffffff : Kernel code
  01200000-01432143 : Kernel data
40000000-fbffffff : System RAM
fd500000-fd50930f : fd500000.pcie pcie@7d500000
fd580000-fd58ffff : fd580000.ethernet ethernet@7d580000
  fd580e14-fd580e1c : unimac-mdio.-19
fe007000-fe007aff : fe007000.dma dma@7e007000
fe007b00-fe007eff : fe007b00.dma dma@7e007b00
fe00a000-fe00a023 : fe100000.watchdog watchdog@7e100000
fe00b840-fe00b87b : fe00b840.mailbox mailbox@7e00b840
fe00b880-fe00b8bf : fe00b880.mailbox mailbox@7e00b880
fe100000-fe100113 : fe100000.watchdog watchdog@7e100000
fe101000-fe102fff : fe101000.cprman cprman@7e101000
fe104000-fe104027 : fe104000.rng rng@7e104000
fe200000-fe2000b3 : fe200000.gpio gpio@7e200000
fe201000-fe2011ff : serial@7e201000
  fe201000-fe2011ff : fe201000.serial serial@7e201000
fe215000-fe215007 : fe215000.aux aux@7e215000
fe300000-fe3000ff : fe300000.mmcnr mmcnr@7e300000
fe340000-fe3400ff : fe340000.emmc2 emmc2@7e340000
fe600000-fe6000ff : fe600000.firmwarekms firmwarekms@7e600000
fec00000-fec03fff : fec00000.v3d hub
fec04000-fec07fff : fec00000.v3d core0
fec11000-fec1101f : fe100000.watchdog watchdog@7e100000
600000000-63fffffff : pcie@7d500000
  600000000-6000fffff : PCI Bus 0000:01
    600000000-600000fff : 0000:01:00.0
      600000000-600000fff : xhci-hcd

root@raspberrypi:/home/pi # i2cdetect -l

i2c-1 i2c bcm2835 (i2c@7e804000) I2C adapter

root@raspberrypi:/home/pi # i2cdetect -y 1

     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --                         

/raspberry pi 有一些自己的特殊命令,如下:

root@raspberrypi:/usr/bin # ls -al raspi*

-rwxr-xr-x 1 root root 84356 2\u6708  10  2021 raspi-config
-rwxr-xr-x 1 root root 20564 10\u6708  1  2019 raspi-gpio
-rwxr-xr-x 1 root root  2383 7\u6708  18  2019 raspinfo
lrwxrwxrwx 1 root root    22 4\u6708  30 22:09 raspistill -> /opt/vc/bin/raspistill
lrwxrwxrwx 1 root root    20 4\u6708  30 22:09 raspivid -> /opt/vc/bin/raspivid
lrwxrwxrwx 1 root root    23 4\u6708  30 22:09 raspividyuv -> /opt/vc/bin/raspividyuv
lrwxrwxrwx 1 root root    20 4\u6708  30 22:09 raspiyuv -> /opt/vc/bin/raspiyuv
root@raspberrypi:/usr/bin # 

root@raspberrypi:/sys/class # cat /boot/config.txt

# For more options and information see
# http://rpf.io/configtxt
# Some settings may impact device functionality. See link above for details

# uncomment if you get no picture on HDMI for a default "safe" mode
#hdmi_safe=1

# uncomment this if your display has a black border of unused pixels visible
# and your display can output without overscan
#disable_overscan=1

# uncomment the following to adjust overscan. Use positive numbers if console
# goes off screen, and negative if there is too much border
#overscan_left=16
#overscan_right=16
#overscan_top=16
#overscan_bottom=16

# uncomment to force a console size. By default it will be display's size minus
# overscan.
#framebuffer_width=1280
#framebuffer_height=720

# uncomment if hdmi display is not detected and composite is being output
#hdmi_force_hotplug=1

# uncomment to force a specific HDMI mode (this will force VGA)
#hdmi_group=1
#hdmi_mode=1

# uncomment to force a HDMI mode rather than DVI. This can make audio work in
# DMT (computer monitor) modes
#hdmi_drive=2

# uncomment to increase signal to HDMI, if you have interference, blanking, or
# no display
#config_hdmi_boost=4

# uncomment for composite PAL
#sdtv_mode=2

#uncomment to overclock the arm. 700 MHz is the default.
#arm_freq=800

# Uncomment some or all of these to enable the optional hardware interfaces
#dtparam=i2c_arm=on
#dtparam=i2s=on
#dtparam=spi=on

# Uncomment this to enable infrared communication.
#dtoverlay=gpio-ir,gpio_pin=17
#dtoverlay=gpio-ir-tx,gpio_pin=18

# Additional overlays and parameters are documented /boot/overlays/README

# Enable audio (loads snd_bcm2835)
dtparam=audio=on

[pi4]
# Enable DRM VC4 V3D driver on top of the dispmanx display stack
dtoverlay=vc4-fkms-v3d
max_framebuffers=2

[all]
#dtoverlay=vc4-fkms-v3d
start_x=1
gpu_mem=128
root@raspberrypi:/sys/class # 

coremark跑分

看到eembc官网的pi4 能跑到 48626分 (https://www.eembc.org/viewer/?benchmark_seq=13417)
我用自己的跑一下,设置开机直接进CLI,然后参考上面别人跑分时的“Compiler Flags‘,输入命令:
make XCFLAGS="-O2 -DMULTITHREAD=4 -DUSE_PTHREAD -DPERFORMANCE_RUN=1 -lrt -pthread"
很快跑完,还是有差距,不确信是否与gcc等有关:

2K performance run parameters for coremark.
CoreMark Size  : 666
Total ticks   : 14204
Total time (secs): 14.204000
Iterations/Sec  : 30977.189524
Iterations    : 440000
Compiler version : GCC8.3.0
Compiler flags  : -O2 -O2 -DMULTITHREAD=4 -DUSE_PTHREAD -DPERFORMANCE_RUN=1 -lrt -pthread -DPERFORMANCE_RUN=1 -lrt
Parallel PThreads : 4
Memory location : Please put data memory location here
(e.g. code in flash, data on heap etc)
seedcrc     : 0xe9f5
[0]crclist    : 0xe714
[1]crclist    : 0xe714
[2]crclist    : 0xe714
[3]crclist    : 0xe714
[0]crcmatrix   : 0x1fd7
[1]crcmatrix   : 0x1fd7
[2]crcmatrix   : 0x1fd7
[3]crcmatrix   : 0x1fd7
[0]crcstate   : 0x8e3a
[1]crcstate   : 0x8e3a
[2]crcstate   : 0x8e3a
[3]crcstate   : 0x8e3a
[0]crcfinal   : 0x33ff
[1]crcfinal   : 0x33ff
[2]crcfinal   : 0x33ff
[3]crcfinal   : 0x33ff
Correct operation validated. See README.md for run and reporting rules.
CoreMark 1.0 : 30977.189524 / GCC8.3.0 -O2 -O2 -DMULTITHREAD=4 -DUSE_PTHREAD -DPERFORMANCE_RUN=1 -lrt -pthread -DPERFORMANCE_RUN=1 -lrt / Heap / 4:PThreads

相关