设备树替换
Seeed在出厂烧录的固件中挂载的设备树为stm32mp1-seeed-npi-base.dtb,默认情况下此设备树是不支持Wi-Fi的,如需使用Wifi功能就需要挂载stm32mp1-seeed-npi-full.dtb这个设备树。
直接修改uEnv.txt文件,此文件会在uboot引导Linux内核的时候主动去加载/boot/dtbs/4.19.9-stm32-r1目录下指定的设备树文件。
1.打开uEnv.txt
vim /boot/uEnv.txt
2.编辑uEnv.txt文件将dtb修改为stm32mp1-seeed-npi-full.dtb
- uname_r=4.19.9-stm32-r1
- #uuid=
- dtb=stm32mp1-seeed-npi-full.dtb ##修改此处
- ###U-Boot Overlays###
- ###Master Enable
- enable_uboot_overlays=1
- ###
- ###custom overlays
- uboot_overlay_addr0=/lib/firmware/stm32mp1-seeed-pwm-overlay.dtbo
- #uboot_overlay_addr0=/lib/firmware/<file0>.dtbo
- #uboot_overlay_addr1=/lib/firmware/<file1>.dtbo
- #uboot_overlay_addr2=/lib/firmware/<file2>.dtbo
- #uboot_overlay_addr3=/lib/firmware/<file3>.dtbo
- #uboot_overlay_addr4=/lib/firmware/<file4>.dtbo
- #uboot_overlay_addr5=/lib/firmware/<file5>.dtbo
- #uboot_overlay_addr6=/lib/firmware/<file6>.dtbo
- #uboot_overlay_addr7=/lib/firmware/<file7>.dtbo
- ###
- ###U-Boot fdt tweaks... (60000 = 384KB)
- #uboot_fdt_buffer=0x60000
- ###U-Boot Overlays###
- cmdline=coherent_pool=1M net.ifnames=0 quiet
- #In the event of edid real failures, uncomment this next line:
- #cmdline=coherent_pool=1M net.ifnames=0 quiet video=HDMI-A-1:1024x768@60e
- #Use an overlayfs on top of a read-only root filesystem:
- #cmdline=coherent_pool=1M net.ifnames=0 quiet overlayroot=tmpfs
- ##enable Generic eMMC Flasher:
- ##make sure, these tools are installed: dosfstools rsync
- #cmdline=init=/opt/scripts/tools/eMMC/init-eMMC-flasher-v3-stm32mp1.sh
- # specify kernel eth0 mac address
- ethaddr=42:9a:42:e1:f7:23
复制代码
Wi-Fi连接
- robot@ev3dev:~$ sudo connmanctl
- Error getting VPN connections: The name net.connman.vpn was not provided by any
- connmanctl> enable wifi
- Enabled wifi
- connmanctl> scan wifi
- Scan completed for wifi
- connmanctl> services
- *AO Wired ethernet_b827ebbde13c_cable
- wifi_e8de27077de3_hidden_managed_none
- AH04044914 wifi_e8de27077de3_41483034303434393134_managed_psk
- Frissie wifi_e8de27077de3_46726973736965_managed_psk
- ruijgt gast wifi_e8de27077de3_7275696a67742067617374_managed_psk
- schuur wifi_e8de27077de3_736368757572_managed_psk
- connmanctl> agent on
- Agent registered
- connmanctl> connect wifi_e8de27077de3_41483034303434393134_managed_psk ##对应的wifi名称的实际编码
- Agent RequestInput wifi_e8de27077de3_41483034303434393134_managed_psk
- Passphrase = [ Type=psk, Requirement=mandatory ]
- Passphrase? ************* ##wifi密码
- Connected wifi_e8de27077de3_41483034303434393134_managed_psk
- connmanctl> quit
复制代码
我们可以使用下面的指令来找到ODYSSEY – STM32MP157C的IP地址:
————————————————
版权声明:Argon_Ghost
|