Where is the source code in built embedded linux distribution?

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

Where is the source code in built embedded linux distribution?

Jump to solution
1,361 Views
anaseem
Contributor IV

I built image for imx8qxpmek evaluation board using Yocto Project.  Where is the source code that exactly matches this image ?

I'm particularly interested in USB Subsystem.  This subsystem must be in u-boot or kernel.

I need to insert printf or printk statements in some files in USB Subsystem and re-build the image for debugging purposes.

Tags (1)
0 Kudos
1 Solution
1,247 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Amer,

The toolchain can be extracted by using the bitbake command:

DISTRO=fsl-imx-fb MACHINE=Target-Machine bitbake core-image-minimal -c populate_sdk

There is a bit of information regarding this on the i.MX Porting Guide. (I refered to the wrong document. Older BSPs do have this information on the Yocto User's Guide, my apologies)

I hope this helps!

Regards,

View solution in original post

4 Replies
1,247 Views
anaseem
Contributor IV

 I can boot from the image I built.  In MCIMX8QXP-CPU evaluation board, I plug in usb stick and it's gets detected as USB Class Mass Storage Device.  When I plug in USB Class Vendor Defined Device, such as Rifle Scope, it doesn't get detected.  I need to debug this problem.  

Is there source code in my Yocto Project host environment?  I need to read source code in vim editor, write printk statements and rebuilt image using Yocto Project.

Do I need to build different type of embedded Linux distribution, like Software Development Kit(SDK) or Application Development Kit(ADK) for debugging source code?

0 Kudos
1,247 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Amer Naseem,

Some USB devices like storage devices may be recognized as the USB driver on the image has built in support, while other devices may require additional drivers which are usually provided by the manufacturer.

The sources are fetched by Yocto in order to build the image. You can find them on the directories inside your build directory. The path may differ between BSP releases buy it’s usually:

/<BSP_DIR>/<BUILD_DIR>/tmp/work/>MACHINE>-poky-linux-gnueabi/<RECIPE>

There is not an ADK per se for Linux. The BSP should serve you as starting point on your application. However, it is based in Yocto, which is focused on distribution rather than development, so it’s recommended that you extract the toolchain for the processor and develop outside of Yocto. You can find more details on how to extract the toolchain from the i.MX Yocto User’s Guide.

I hope this helps!

Regards,

0 Kudos
1,247 Views
anaseem
Contributor IV

Yes, it's very helpful.  Now, I found the source code.  Thank you!

I didn't find information on extracting toolchain for the processor?

Regards,

Amer

0 Kudos
1,248 Views
gusarambula
NXP TechSupport
NXP TechSupport

Hello Amer,

The toolchain can be extracted by using the bitbake command:

DISTRO=fsl-imx-fb MACHINE=Target-Machine bitbake core-image-minimal -c populate_sdk

There is a bit of information regarding this on the i.MX Porting Guide. (I refered to the wrong document. Older BSPs do have this information on the Yocto User's Guide, my apologies)

I hope this helps!

Regards,