Z-turn-Board-V2-Diary

🌷 Creating (and compiling) a project 🌌


Outline:


🏛️(Create a new project):

We will not be using pre-configured settings. (This would be possible by using a bsp file).
(Thus, we will rely on templates).


🏛️(menuconfig: Cache)

To save download time, we can download various caches. There are two of them, the “download” and the “sstate” one. Namely, under the PetaLinux Tools sstate-cache Artifacts, the following can be downloaded:

Extract both of them and note the destination paths like so:

To set them:


🏛️(menuconfig: New partition)

(Instead of loading Linux onto [board’s] RAM (default/image.ub)),
We will install, Linux, directly onto the SD(ext4) card.


🏛️(menuconfig: Extra(threads))


🏛️(menuconfig: Extra(auto-login))

(As per reference), Open the rootfs configuration:
$ petalinux-config -c rootfs


🏛️(SD read-write):

In order to not boot read-only, we’ll need a device tree specification.
Taken from the original source code, we’ll adapt the device tree specifications (files system-user.dtsi and zturn-pl-hdmi.dtsi (the .dtsi stands for Device Tree Source Include)), too isolate the SD part: (and adapt the system-user.dtsi file):

my_project/project-spec/meta-user/recipes-bsp/device-tree/files/system-user.dtsi:

/include/ "system-conf.dtsi"
/ {
    aliases {
		mmc0 = &sdhci0;
	};
};

&sdhci0 {
	status = "okay";
	disable-wp;
	// wp-inverted;
};

🏛️(Build the project):


🏛️(Package the boot images):

FIXME: Why?


Note(corrections)

As per the tutorial:

Thus, up to the previous chapter, the ext4 (where the rootfs.tar.gz was extracted) was not being used 🙊!


Boot:

As per reference:

(You can monitor the boot process with picocom or CuteCom).


Various troubleshooting from the internet:


Referencies