[yocto] How do I used Yocto to build an sdcard image for my Raspberry Pi 3 Model B?

Khem Raj raj.khem at gmail.com
Wed Nov 2 22:41:40 PDT 2016

Do you see an image with .rpi-sdimg in deploy/images/raspberrypi3

 % ls *.rpi-sdimg

Thats the one you should be able to dd

> On Nov 2, 2016, at 6:10 AM, Thomas A. F. Thorne MEng AUS MIET <Thomas.Thorne at Net2Edge.com> wrote:
> I was starting to look at using Yocto <https://www.yoctoproject.org/> as a system for building software images for the Raspberry Pi 3 Model B that I have. I wanted to try using Yocto as there are some projects at my office that may begin using it in the future. One of the nice points is that all the setup of cross compilers for your target system is handled by a Yocto layer. There is already a Yocto layer for the Raspberry Pi <http://git.yoctoproject.org/cgit/cgit.cgi/meta-raspberrypi/>(meta-raspberrypi <http://git.yoctoproject.org/cgit/cgit.cgi/meta-raspberrypi/>) and a custom meta-rpi <https://github.com/jumpnow/meta-rpi> layer someone has put together with a few more example images.
> I need to either cross-compile kernel modules or use Yocto as I have special drivers I wish to add to the Pi. These are already compiled and working on my Ubuntu PC and I hoped using Yocto might make it easy to cross compile these and any other updates in the future.
> My difficulty is that the SD Card image talked about in the meta-raspberrypi documentation <http://git.yoctoproject.org/cgit/cgit.cgi/meta-raspberrypi/about/> and several tutorials, never gets generated, even on successful builds.
> Tutorials Mentioning The Use Of dd & An .sdimg File
> Build a Raspberry Pi 2 Minimal Image with The Yocto Project <http://www.cnx-software.com/2015/02/27/yocto-project-raspberry-pi-2-board-minimal-image/>
> Building Raspberry Pi Systems with Yocto <http://www.jumpnowtek.com/rpi/Raspberry-Pi-Systems-with-Yocto.html>
> 12MB Minimal Image for Raspberry Pi using the Yocto Project <http://www.cnx-software.com/2013/07/05/12mb-minimal-image-for-raspberry-pi-using-the-yocto-project/>
> Poky Raspberry Pi SD Card Image <http://www.crashcourse.ca/wiki/index.php/Poky_Raspberry_Pi_SD_Card_Image>
> Commonly Seen Error
> None of the builds I have made so far generate .sdimg files. When I try to add the sdcard or sdcard_image-rpi image types to IMAGE_FSTYPES I get messages such as:
> ERROR: /home/thomasthorne/work/yocto-rpi/meta-raspberrypi/recipes-core/images/rpi-test-image.bb: No IMAGE_CMD defined for IMAGE_FSTYPES entry 'sdcard_image-rpi' - possibly invalid type name or missing support class
> Main Questions
> How do I generate the SD card image for my Pi from Yocto?
> Do I need to format the SD card manually and copy over the contents bit by bit?
> Why do all these tutorials suggest it would be as simple as a single dd command? I guess something changed in the last couple of years and they are all out of date.
> This was also posted at http://raspberrypi.stackexchange.com/questions/57155/how-do-i-used-yocto-to-build-an-sdcard-image-for-my-raspberry-pi-3-model-b <http://raspberrypi.stackexchange.com/questions/57155/how-do-i-used-yocto-to-build-an-sdcard-image-for-my-raspberry-pi-3-model-b>before I realised it is probably more of a Yocto question than a Raspberry Pi one.
> I will be very grateful of any help or advice you can offer.  Even an explanation of when the generation of SD card images was dropped from the Yocto Project would be very helpful.
> Regards,
> --
> Thomas A. F. Thorne MEng. AUS MIET
> Software Engineer
> Tel: +44 3450 130 030 <tel:+443450130030>
> Email: Thomas.Thorne at Net2Edge.com <mailto:Thomas.Thorne at Net2Edge.com>
> Web: http://www.Net2Edge.com/ <http://www.net2edge.com/>
> Net2Edge Limited is a company registered in England & Wales (Company No. 2438435, VAT No. GB 537553821) Passfield Oak, Liphook, Hampshire, GU30 7RL. This email transmission is confidential and intended solely for the person or organisation to whom it is addressed. If you are not the intended recipient, you must not copy, distribute or disseminate the information, or take any action in reliance of it. Any views expressed in this message are those of the individual sender, except where the sender specifically states them to be the views of any organisation or employer. If you have received this message in error, do not open any attachment but please notify the sender (above) and delete this message from your system. Please rely on your own virus check. Although all outbound mail is checked for viruses, no responsibility is taken by the sender for any damage rising out of any bug or virus infection.
> --
> _______________________________________________
> yocto mailing list
> yocto at yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20161102/68f27ce2/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 204 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20161102/68f27ce2/attachment.pgp>

More information about the yocto mailing list