How to use fdtput on i.MX Yocto

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to use fdtput on i.MX Yocto

Jump to solution
3,026 Views
jun_1
Contributor IV

I have i.MX 8M Mini EVK which runs Linux 6.6.23_2.0.0.
To configure the SDIO Interface, I run the following command:

fdtput /run/media/boot-mmcblk2p1/imx8mm-evk.dtb /soc@0/bus@30800000/mmc@30b50000 no-1-8-v

However, I got “-sh: fdtput: command not found". I also run “sudo apt-get install device-tree-compile” to install fdtput command, and I got “Building dependency tree... Done E: Unable to locate package fdtput” error.

How can I use fdtput command?

Labels (2)
0 Kudos
Reply
1 Solution
2,930 Views
yipingwang
NXP TechSupport
NXP TechSupport

The rootfs provided in i.MX Linux SDK 6.6.23_2.0.0 is not Ubuntu rootfs, so the command "sudo apt-get install device-tree-compiler" doesn't work.

You could add "dtc" to rebuild rootfs in Yocto build environment.

I built attached "dtc" binaries file for you, please copy the attached tar ball to your target board directly.

# tar -xzvf image.tar.gz

# cp image/usr/lib/* /usr/lib/

# cp ./image/usr/bin/fdtput /usr/bin/

# fdtput

View solution in original post

0 Kudos
Reply
4 Replies
2,895 Views
jun_1
Contributor IV

Thank you. I successed to execute the command using the above method.

0 Kudos
Reply
3,000 Views
yipingwang
NXP TechSupport
NXP TechSupport

Please use the following command.

$ sudo apt-get install device-tree-compiler

0 Kudos
Reply
2,994 Views
jun_1
Contributor IV
Thank you for your reply.
I tried the following command, and I got “Building dependency tree... Done E: Unable to locate package fdtput” error; it was a copy and paste mistake.

$ sudo apt-get install device-tree-compiler
0 Kudos
Reply
2,931 Views
yipingwang
NXP TechSupport
NXP TechSupport

The rootfs provided in i.MX Linux SDK 6.6.23_2.0.0 is not Ubuntu rootfs, so the command "sudo apt-get install device-tree-compiler" doesn't work.

You could add "dtc" to rebuild rootfs in Yocto build environment.

I built attached "dtc" binaries file for you, please copy the attached tar ball to your target board directly.

# tar -xzvf image.tar.gz

# cp image/usr/lib/* /usr/lib/

# cp ./image/usr/bin/fdtput /usr/bin/

# fdtput

0 Kudos
Reply
%3CLINGO-SUB%20id%3D%22lingo-sub-2018564%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EHow%20to%20use%20fdtput%20on%20i.MX%20Yocto%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2018564%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EI%20have%20i.MX%208M%20Mini%20EVK%20which%20runs%20Linux%206.6.23_2.0.0.%3CBR%20%2F%3ETo%20configure%20the%20SDIO%20Interface%2C%20I%20run%20the%20following%20command%3A%3C%2FP%3E%3CP%3Efdtput%20%2Frun%2Fmedia%2Fboot-mmcblk2p1%2Fimx8mm-evk.dtb%20%2Fsoc%400%2Fbus%4030800000%2Fmmc%4030b50000%20no-1-8-v%3C%2FP%3E%3CP%3EHowever%2C%20I%20got%20%E2%80%9C-sh%3A%20fdtput%3A%20command%20not%20found%22.%20I%20also%20run%20%E2%80%9Csudo%20apt-get%20install%20device-tree-compile%E2%80%9D%20to%20install%20fdtput%20command%2C%20and%20I%20got%20%E2%80%9CBuilding%20dependency%20tree...%20Done%20E%3A%20Unable%20to%20locate%20package%20fdtput%E2%80%9D%20error.%3C%2FP%3E%3CP%3EHow%20can%20I%20use%20fdtput%20command%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2018564%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CLINGO-LABEL%3EEvaluation%20Board%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3ERF%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2022860%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20How%20to%20use%20fdtput%20on%20i.MX%20Yocto%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2022860%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EThank%20you.%26nbsp%3BI%20successed%20to%20execute%20the%20command%20using%20the%20above%20method.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2021688%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20How%20to%20use%20fdtput%20on%20i.MX%20Yocto%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2021688%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EThe%20rootfs%20provided%20in%20i.MX%26nbsp%3B%3CSPAN%3ELinux%20SDK%206.6.23_2.0.0%20is%20not%20Ubuntu%20rootfs%2C%20so%20the%20command%20%22sudo%20apt-get%20install%20device-tree-compiler%22%20doesn't%20work.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EYou%20could%20add%20%22dtc%22%20to%20rebuild%20rootfs%20in%20Yocto%20build%20environment.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EI%20built%20attached%20%22dtc%22%20binaries%20file%20for%20you%2C%20please%20copy%20the%20attached%20tar%20ball%20to%20your%20target%20board%20directly.%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%23%20tar%20-xzvf%20image.tar.gz%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%23%20cp%20image%2Fusr%2Flib%2F*%20%2Fusr%2Flib%2F%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%23%20cp%20.%2Fimage%2Fusr%2Fbin%2Ffdtput%20%2Fusr%2Fbin%2F%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3E%23%20fdtput%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2019018%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20How%20to%20use%20fdtput%20on%20i.MX%20Yocto%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2019018%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EThank%20you%20for%20your%20reply.%3CBR%20%2F%3EI%20tried%20the%20following%20command%2C%20and%20I%20got%20%E2%80%9CBuilding%20dependency%20tree...%20Done%20E%3A%20Unable%20to%20locate%20package%20fdtput%E2%80%9D%20error%3B%20it%20was%20a%20copy%20and%20paste%20mistake.%3CBR%20%2F%3E%3CBR%20%2F%3E%24%20sudo%20apt-get%20install%20device-tree-compiler%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2018987%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3ERe%3A%20How%20to%20use%20fdtput%20on%20i.MX%20Yocto%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2018987%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EPlease%20use%20the%20following%20command.%3C%2FP%3E%0A%3CP%3E%24%20sudo%20apt-get%20install%20device-tree-compiler%3C%2FP%3E%3C%2FLINGO-BODY%3E