summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/README.md53
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/conf/layer.conf14
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/app.json49
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/initial_vscreen.json20
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/uhmi-ivi-wm.conf3
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-receiver.config7
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-sender.config7
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/set-hostname.inc5
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-receiver.bb22
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-sender.bb29
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/files/weston_ivi-shell.ini50
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/weston-init.bbappend13
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-receiver.bb18
-rw-r--r--meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-sender.bb19
-rw-r--r--templates/feature/agl-uhmi-demo/50_bblayers.conf.inc3
-rw-r--r--templates/feature/agl-uhmi-demo/50_local.conf.inc1
-rw-r--r--templates/feature/agl-uhmi-demo/included.dep2
17 files changed, 315 insertions, 0 deletions
diff --git a/meta-uhmi/meta-agl-uhmi-demo/README.md b/meta-uhmi/meta-agl-uhmi-demo/README.md
new file mode 100644
index 00000000..df956f04
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/README.md
@@ -0,0 +1,53 @@
+# Unified HMI preconfigured demo images
+
+## Introduction
+Unified HMI needs a litle complex environment setup, so here we provide a recipe that allow you to create a pre-configured images.
+
+## Unified HMI frameworks
+For a detailed explanation of Unified HMI, please refer to the [AGL Documentation](https://docs.automotivelinux.org/en/master/#06_Component_Documentation/11_Unified_HMI/)
+
+## Demo environment
+Demo images supports three boards: qemux-86-64, raspberrypi4, and agl-refhw.
+Please prepare two boards, one is the sender and the other is the receiver, on any boards and build the respective images for each.
+
+* sender
+```
+IP: 192.168.0.100
+HOSTNAME: agl-host0
+```
+
+* receiver
+```
+IP: 192.168.0.101
+HOSTNAME: agl-host1
+```
+
+## How to build
+Follow the [AGL documentation](https://docs.automotivelinux.org/en/master/#01_Getting_Started/02_Building_AGL_Image/01_Build_Process_Overview/) for the build process, and set up the "[Initializing Your Build Environment](https://docs.automotivelinux.org/en/master/#01_Getting_Started/02_Building_AGL_Image/04_Initializing_Your_Build_Environment/)" section as described below to enable the AGL feature 'agl-uhmi-demo'.
+
+For example:
+```
+$ cd $AGL_TOP/master
+$ source ./meta-agl/scripts/aglsetup.sh -m qemux86-64 -b qemux86-64 agl-devel agl-uhmi-demo
+```
+
+After adding the feature, execute the bitbake command:
+
+for sender
+```
+$ bitbake agl-uhmi-demo-preconfigured-sender
+```
+
+for receiver
+```
+$ bitbake agl-uhmi-demo-preconfigured-receiver
+```
+
+## How to use
+After both the sender and receiver have successfully booted, you can execute the following commands on the sender to confirm that the application is displayed across two displays each connected to diferrent boards.
+
+on sender (IP:192.168.0.100, hostname:agl-host0):
+```
+$ cat /var/local/uhmi-app/glmark2/app.json | ucl-distrib-com /etc/uhmi-framework/virtual-screen-def.json &
+$ cat /var/local/uhmi-app/glmark2/initial_vscreen.json | ula-distrib-com
+```
diff --git a/meta-uhmi/meta-agl-uhmi-demo/conf/layer.conf b/meta-uhmi/meta-agl-uhmi-demo/conf/layer.conf
new file mode 100644
index 00000000..3d3466b1
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/conf/layer.conf
@@ -0,0 +1,14 @@
+# We have a conf and classes directory, add to BBPATH
+BBPATH =. "${LAYERDIR}:"
+
+# We have recipes-* directories, add to BBFILES
+BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
+ ${LAYERDIR}/recipes-*/*/*.bbappend"
+
+BBFILE_COLLECTIONS += "agl-uhmi-demo-layer"
+BBFILE_PATTERN_agl-uhmi-demo-layer = "^${LAYERDIR}/"
+BBFILE_PRIORITY_agl-uhmi-demo-layer = "70"
+
+LAYERSERIES_COMPAT_agl-uhmi-demo-layer = "scarthgap"
+
+LAYERDEPENDS_agl-uhmi-demo-layer = "agldemo"
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/app.json b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/app.json
new file mode 100644
index 00000000..1dcce8aa
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/app.json
@@ -0,0 +1,49 @@
+{
+ "format_v1": {
+ "command_type" : "remote_virtio_gpu",
+ "appli_name" : "glmark2",
+ "sender" : {
+ "launcher" : "agl-host0",
+ "command" : "/usr/bin/ucl-virtio-gpu-wl-send",
+ "frontend_params" : {
+ "scanout_x" : 0,
+ "scanout_y" : 0,
+ "scanout_w" : 1920,
+ "scanout_h" : 1080,
+ "server_port" : 33445
+ },
+ "appli" : "/usr/bin/glmark2-es2-wayland -s 1920x1080",
+ "env" : "LD_LIBRARY_PATH=/usr/lib/mesa-virtio"
+ },
+ "receivers" : [
+ {
+ "launcher" : "agl-host0",
+ "command" : "/usr/bin/ucl-virtio-gpu-wl-recv",
+ "backend_params" : {
+ "ivi_surface_id" : 101000,
+ "scanout_x" : 0,
+ "scanout_y" : 0,
+ "scanout_w" : 1920,
+ "scanout_h" : 1080,
+ "listen_port" : 33445,
+ "initial_screen_color" : "0x33333333"
+ },
+ "env" : "XDG_RUNTIME_DIR=/run/user/200 WAYLAND_DISPLAY=wayland-1"
+ },
+ {
+ "launcher" : "agl-host1",
+ "command" : "/usr/bin/ucl-virtio-gpu-wl-recv",
+ "backend_params" : {
+ "ivi_surface_id" : 101000,
+ "scanout_x" : 0,
+ "scanout_y" : 0,
+ "scanout_w" : 1920,
+ "scanout_h" : 1080,
+ "listen_port" : 33445,
+ "initial_screen_color" : "0x33333333"
+ },
+ "env" : "XDG_RUNTIME_DIR=/run/user/200 WAYLAND_DISPLAY=wayland-1"
+ }
+ ]
+ }
+}
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/initial_vscreen.json b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/initial_vscreen.json
new file mode 100644
index 00000000..d6ac7771
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/initial_vscreen.json
@@ -0,0 +1,20 @@
+{
+ "command": "initial_vscreen",
+ "vlayer": [
+ {
+ "VID": 1010000,
+ "coord": "global",
+ "virtual_w": 1920, "virtual_h": 1080,
+ "vsrc_x": 0, "vsrc_y": 0, "vsrc_w": 1920, "vsrc_h": 1080,
+ "vdst_x": 960, "vdst_y": 0, "vdst_w": 1920, "vdst_h": 1080,
+ "vsurface": [
+ {
+ "VID": 101000,
+ "pixel_w": 1920, "pixel_h": 1080,
+ "psrc_x": 0, "psrc_y": 0, "psrc_w": 1920, "psrc_h": 1080,
+ "vdst_x": 0, "vdst_y": 0, "vdst_w": 1920, "vdst_h": 1080
+ }
+ ]
+ }
+ ]
+}
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/uhmi-ivi-wm.conf b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/uhmi-ivi-wm.conf
new file mode 100644
index 00000000..546a61c4
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/uhmi-ivi-wm.conf
@@ -0,0 +1,3 @@
+[Service]
+Environment="XDG_RUNTIME_DIR=/run/user/200"
+Environment="WAYLAND_DISPLAY=wayland-1"
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-receiver.config b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-receiver.config
new file mode 100644
index 00000000..9d6b3a63
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-receiver.config
@@ -0,0 +1,7 @@
+[global]
+Name = Wired
+Description = Wired network configuration
+
+[service_ether]
+Type = ethernet
+IPv4 = 192.168.0.101/24
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-sender.config b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-sender.config
new file mode 100644
index 00000000..777a3e95
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/files/wired-sender.config
@@ -0,0 +1,7 @@
+[global]
+Name = Wired
+Description = Wired network configuration
+
+[service_ether]
+Type = ethernet
+IPv4 = 192.168.0.100/24
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/set-hostname.inc b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/set-hostname.inc
new file mode 100644
index 00000000..9ff5339e
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/set-hostname.inc
@@ -0,0 +1,5 @@
+set_hostname() {
+ UHMI_HOSTNAME=${UHMI_HOSTNAME:-agl-host}
+ echo "${UHMI_HOSTNAME}" > ${IMAGE_ROOTFS}/${sysconfdir}/hostname
+}
+ROOTFS_POSTPROCESS_COMMAND:append = " set_hostname;"
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-receiver.bb b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-receiver.bb
new file mode 100644
index 00000000..94092b13
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-receiver.bb
@@ -0,0 +1,22 @@
+SUMMARY = "Setting files for UHMI receiver"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+SRC_URI = " \
+ file://wired-receiver.config \
+ file://uhmi-ivi-wm.conf \
+"
+
+do_install() {
+ if [ ! -e ${D}/var/lib/connman/wired.config ]; then
+ install -d ${D}/var/lib/connman/
+ install -m 6444 ${WORKDIR}/wired-receiver.config ${D}/var/lib/connman/wired.config
+ fi
+
+ install -d ${D}/etc/systemd/system/uhmi-ivi-wm.service.d/
+ install -m 0644 ${WORKDIR}/uhmi-ivi-wm.conf ${D}/etc/systemd/system/uhmi-ivi-wm.service.d/
+}
+
+FILES:${PN} += " \
+ /var/lib/connman/wired.config \
+"
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-sender.bb b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-sender.bb
new file mode 100644
index 00000000..ee854d85
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-config/uhmi-config/uhmi-config-sender.bb
@@ -0,0 +1,29 @@
+SUMMARY = "Setting files for UHMI sender"
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
+
+SRC_URI = " \
+ file://app.json \
+ file://initial_vscreen.json \
+ file://wired-sender.config \
+ file://uhmi-ivi-wm.conf \
+"
+
+do_install() {
+ if [ ! -e ${D}/var/lib/connman/wired.config ]; then
+ install -d ${D}/var/lib/connman/
+ install -m 6444 ${WORKDIR}/wired-sender.config ${D}/var/lib/connman/wired.config
+ fi
+
+ install -d ${D}/var/local/uhmi-app/glmark2
+ install -m 644 ${WORKDIR}/app.json ${D}/var/local/uhmi-app/glmark2/
+ install -m 644 ${WORKDIR}/initial_vscreen.json ${D}/var/local/uhmi-app/glmark2/
+
+ install -d ${D}/etc/systemd/system/uhmi-ivi-wm.service.d/
+ install -m 0644 ${WORKDIR}/uhmi-ivi-wm.conf ${D}/etc/systemd/system/uhmi-ivi-wm.service.d/
+}
+
+FILES:${PN} += " \
+ /var/lib/connman/wired.config \
+ /var/local/uhmi-app/glmark2 \
+"
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/files/weston_ivi-shell.ini b/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/files/weston_ivi-shell.ini
new file mode 100644
index 00000000..5001d11e
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/files/weston_ivi-shell.ini
@@ -0,0 +1,50 @@
+[core]
+shell=ivi-shell.so
+modules=ivi-controller.so
+require-input=false
+
+[output]
+name=HDMI-A-1
+mode=1920x1080@60
+
+[output]
+name=HDMI-A-2
+mode=1920x1080@60
+
+[output]
+name=HDMI-A-3
+mode=1920x1080@60
+
+[output]
+name=DSI-1
+mode=1920x1080@60
+
+[output]
+name=DSI-2
+mode=1920x1080@60
+
+[output]
+name=DP-1
+mode=1920x1080@60
+
+[output]
+name=Virtual-1
+mode=1920x1080
+
+[output]
+name=Virtual-2
+mode=1920x1080
+
+[output]
+name=VGA-1
+mode=1920x1080
+
+[output]
+name=VGA-2
+mode=1920x1080
+
+[ivi-shell]
+ivi-input-module=ivi-input-controller.so
+#ivi-client-name=/usr/bin/simple-weston-client
+bkgnd-surface-id=1000000
+bkgnd-color=0xFF000000
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/weston-init.bbappend b/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/weston-init.bbappend
new file mode 100644
index 00000000..1cc6091c
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-graphics/wayland/weston-init.bbappend
@@ -0,0 +1,13 @@
+FILESEXTRAPATHS:prepend := "${THISDIR}/files:"
+
+WESTON_INIT_IVI_SHELL ?= "weston_ivi-shell.ini"
+
+SRC_URI:append = " \
+ file://${WESTON_INIT_IVI_SHELL} \
+"
+
+do_install:append () {
+ install -d ${D}/${sysconfdir}/xdg/weston
+ install -m 644 ${WORKDIR}/${WESTON_INIT_IVI_SHELL} ${D}/${sysconfdir}/xdg/weston/
+ ln -nfs ${sysconfdir}/xdg/weston/${WESTON_INIT_IVI_SHELL} ${D}/${sysconfdir}/xdg/weston/weston.ini
+}
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-receiver.bb b/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-receiver.bb
new file mode 100644
index 00000000..1e7de2c0
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-receiver.bb
@@ -0,0 +1,18 @@
+SUMMARY = "AGL Unified HMI demo preconfigured weston receiver image"
+LICENSE = "MIT"
+
+DEPENDS = "uhmi-ivi-wm"
+
+require recipes-platform/images/agl-image-weston.bb
+
+IMAGE_FEATURES += "ssh-server-openssh"
+
+# Add packages for Unified HMI demo platform here
+IMAGE_INSTALL += " \
+ packagegroup-rvgpu \
+ packagegroup-ddfw \
+ uhmi-config-receiver \
+"
+
+UHMI_HOSTNAME ?= "agl-host1"
+require recipes-config/uhmi-config/set-hostname.inc
diff --git a/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-sender.bb b/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-sender.bb
new file mode 100644
index 00000000..5c9d6a2b
--- /dev/null
+++ b/meta-uhmi/meta-agl-uhmi-demo/recipes-platform/images/agl-uhmi-demo-preconfigured-sender.bb
@@ -0,0 +1,19 @@
+SUMMARY = "AGL Unified HMI demo preconfigured weston sender image"
+LICENSE = "MIT"
+
+DEPENDS = "uhmi-ivi-wm"
+
+require recipes-platform/images/agl-image-weston.bb
+
+IMAGE_FEATURES += "ssh-server-openssh"
+
+# Add packages for Unified HMI demo platform here
+IMAGE_INSTALL += " \
+ packagegroup-rvgpu \
+ packagegroup-ddfw \
+ uhmi-config-sender \
+ glmark2 \
+"
+
+UHMI_HOSTNAME ?= "agl-host0"
+require recipes-config/uhmi-config/set-hostname.inc
diff --git a/templates/feature/agl-uhmi-demo/50_bblayers.conf.inc b/templates/feature/agl-uhmi-demo/50_bblayers.conf.inc
new file mode 100644
index 00000000..9048d828
--- /dev/null
+++ b/templates/feature/agl-uhmi-demo/50_bblayers.conf.inc
@@ -0,0 +1,3 @@
+BBLAYERS =+ " \
+ ${METADIR}/meta-agl-devel/meta-uhmi/meta-agl-uhmi-demo \
+"
diff --git a/templates/feature/agl-uhmi-demo/50_local.conf.inc b/templates/feature/agl-uhmi-demo/50_local.conf.inc
new file mode 100644
index 00000000..8ae7b749
--- /dev/null
+++ b/templates/feature/agl-uhmi-demo/50_local.conf.inc
@@ -0,0 +1 @@
+AGL_EXTRA_IMAGE_FSTYPES = "ext4"
diff --git a/templates/feature/agl-uhmi-demo/included.dep b/templates/feature/agl-uhmi-demo/included.dep
new file mode 100644
index 00000000..9d33e122
--- /dev/null
+++ b/templates/feature/agl-uhmi-demo/included.dep
@@ -0,0 +1,2 @@
+agl-demo
+agl-uhmi