agl-service-hvac: add updated recipes 39/27739/2
authorScott Murray <scott.murray@konsulko.com>
Thu, 16 Jun 2022 04:48:55 +0000 (00:48 -0400)
committerScott Murray <scott.murray@konsulko.com>
Wed, 6 Jul 2022 18:32:43 +0000 (14:32 -0400)
Add recipes to build the new incarnation of VIS client daemon version
of agl-service-hvac and for installing associated demo platform
configuration files for the full AGL demo setup.  As well, add the
new packages from these recipes to the appropriate packagegroups.

Bug-AGL: SPEC-4409

Signed-off-by: Scott Murray <scott.murray@konsulko.com>
Change-Id: I34fae0a6e2c3ed387757eb01a9c8042ba14fbd0f

recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf.bb [new file with mode: 0644]
recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/agl-service-hvac-can.conf.demo [new file with mode: 0644]
recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/sllin.conf [new file with mode: 0644]
recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.conf [new file with mode: 0644]
recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.token [new file with mode: 0644]
recipes-demo/agl-service-hvac/agl-service-hvac_git.bb [new file with mode: 0644]
recipes-platform/packagegroups/packagegroup-agl-demo-preload.bb
recipes-platform/packagegroups/packagegroup-agl-ivi-services.bb

diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf.bb b/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf.bb
new file mode 100644 (file)
index 0000000..7598790
--- /dev/null
@@ -0,0 +1,31 @@
+SUMMARY     = "AGL demo configuration for HVAC service daemon"
+HOMEPAGE    = "https://gerrit.automotivelinux.org/gerrit/#/admin/projects/apps/agl-service-hvac"
+SECTION     = "apps"
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+SRC_URI = "file://agl-service-hvac-can.conf.demo \
+           file://sllin.conf \
+"
+
+PACKAGE_ARCH = "${MACHINE_ARCH}"
+
+do_configure[noexec] = "1"
+do_compile[noexec] = "1"
+
+do_install () {
+    # Install configuration file to use sllin0 instead of the default
+    # can0 CAN device.
+    install -D -m 644 ${WORKDIR}/agl-service-hvac-can.conf.demo ${D}${sysconfdir}/xdg/AGL/agl-service-hvac-can.conf
+
+    # Install systemd override to add a dependency on kuksa-dbc-feeder-sllin.service,
+    # which currently brings up sllin0.  This will need to be reworked in the future
+    # to be a bit more straightforward.
+    install -d ${D}${systemd_system_unitdir}/agl-service-hvac.service.d
+    install -m 0644 ${WORKDIR}/sllin.conf ${D}${systemd_system_unitdir}/agl-service-hvac.service.d/
+}
+
+FILES:${PN} += "${systemd_system_unitdir}"
+
+RDEPENDS:${PN} += "agl-service-hvac kuksa-dbc-feeder-sllin"
diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/agl-service-hvac-can.conf.demo b/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/agl-service-hvac-can.conf.demo
new file mode 100644 (file)
index 0000000..d2e0bb3
--- /dev/null
@@ -0,0 +1,2 @@
+[can]
+port = "sllin0"
diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/sllin.conf b/recipes-demo/agl-service-hvac/agl-service-hvac-demo-conf/sllin.conf
new file mode 100644 (file)
index 0000000..f4df185
--- /dev/null
@@ -0,0 +1,3 @@
+[Unit]
+Requires=kuksa-dbc-feeder-sllin.service
+After=kuksa-dbc-feeder-sllin.service
diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.conf b/recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.conf
new file mode 100644 (file)
index 0000000..31f22ff
--- /dev/null
@@ -0,0 +1,2 @@
+[vis-client]
+authorization = "/etc/xdg/AGL/agl-service-hvac/agl-service-hvac.token"
diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.token b/recipes-demo/agl-service-hvac/agl-service-hvac/agl-service-hvac.token
new file mode 100644 (file)
index 0000000..770aadc
--- /dev/null
@@ -0,0 +1 @@
+eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiJ9.eyJzdWIiOiJrdWtzYS52YWwiLCJpc3MiOiJFY2xpcHNlIEtVS1NBIERldiIsImFkbWluIjp0cnVlLCJpYXQiOjE1MTYyMzkwMjIsImV4cCI6MTc2NzIyNTU5OSwia3Vrc2EtdnNzIjp7IioiOiJydyJ9fQ.QQcVR0RuRJIoasPXYsMGZhdvhLjUalk4GcRaxhh3-0_j3CtVSZ0lTbv_Z3As5BfIYzaMlwUzFGvCVOq2MXVjRK81XOAZ6wIsyKOxva16zjbZryr2V_m3yZ4twI3CPEzJch11_qnhInirHltej-tGg6ySfLaTYeAkw4xYGwENMBBhN5t9odANpScZP_xx5bNfwdW1so6FkV1WhpKlCywoxk_vYZxo187d89bbiu-xOZUa5D-ycFkd1-1rjPXLGE_g5bc4jcQBvNBc-5FDbvt4aJlTQqjpdeppxhxn_gjkPGIAacYDI7szOLC-WYajTStbksUju1iQCyli11kPx0E66me_ZVwOX07f1lRF6D2brWm1LcMAHM3bQUK0LuyVwWPxld64uSAEsvSKsRyJERc7nZUgLf7COnUrrkxgIUNjukbdT2JVN_I-3l3b4YXg6JVD7Y5g0QYBKgXEFpZrDbBVhzo7PXPAhJD6-c3DcUQyRZExbrnFV56RwWuExphw8lYnbMvxPWImiVmB9nRVgFKD0TYaw1sidPSSlZt8Uw34VZzHWIZQAQY0BMjR33fefg42XQ1YzIwPmDx4GYXLl7HNIIVbsRsibKaJnf49mz2qnLC1K272zXSPljO11Ke1MNnsnKyUH7mcwEs9nhTsnMgEOx_TyMLRYo-VEHBDLuEOiBo
\ No newline at end of file
diff --git a/recipes-demo/agl-service-hvac/agl-service-hvac_git.bb b/recipes-demo/agl-service-hvac/agl-service-hvac_git.bb
new file mode 100644 (file)
index 0000000..094a1b5
--- /dev/null
@@ -0,0 +1,38 @@
+SUMMARY     = "Demo HVAC Service Daemon"
+DESCRIPTION = "Demo HVAC Service Daemon"
+HOMEPAGE    = "https://gerrit.automotivelinux.org/gerrit/#/admin/projects/apps/agl-service-hvac"
+
+LICENSE     = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=ae6497158920d9524cf208c09cc4c984"
+
+DEPENDS = "boost openssl nlohmann-json systemd"
+
+SRC_URI = "git://gerrit.automotivelinux.org/gerrit/apps/agl-service-hvac;protocol=https;branch=${AGL_BRANCH} \
+           file://agl-service-hvac.conf \
+           file://agl-service-hvac.token \
+"
+SRCREV  = "096908375ecbfc6388d0aec69a35b2a8ffc53d47"
+
+PV = "2.0+git${SRCPV}"
+S  = "${WORKDIR}/git"
+
+inherit meson pkgconfig systemd
+
+SYSTEMD_SERVICE:${PN} = "agl-service-hvac.service"
+
+do_install:append() {
+    # Currently using default global client and CA certificates
+    # for KUKSA.val SSL, installing app specific ones would go here.
+
+    # VIS authorization token file for KUKSA.val should ideally not
+    # be readable by other users, but currently that's not doable
+    # until a packaging/sandboxing/MAC scheme is (re)implemented or
+    # something like OAuth is plumbed in as an alternative.
+    install -d ${D}${sysconfdir}/xdg/AGL/agl-service-hvac
+    install -m 0644 ${WORKDIR}/agl-service-hvac.conf ${D}${sysconfdir}/xdg/AGL/
+    install -m 0644 ${WORKDIR}/agl-service-hvac.token ${D}${sysconfdir}/xdg/AGL/agl-service-hvac/
+}
+
+FILES:${PN} += "${systemd_system_unitdir}"
+
+RDEPENDS:${PN} += "kuksa-val"
index 25a3795..317b900 100644 (file)
@@ -9,7 +9,7 @@ PACKAGES = " \
 "
 
 # NOTES:
-# - demo-i2x-udev-conf:
+# - demo-i2c-udev-conf:
 #     Adds udev configuration and scripts for supporting USB attached
 #     I2C devices for RTC and HVAC LED support.
 # - sllin-demo:
@@ -20,6 +20,9 @@ PACKAGES = " \
 #     Adds configuration and systemd unit to run a second instance of
 #     the DBC feeder against the sllin0 interface to connect the
 #     steering wheel controls into VIS.
+# - agl-service-hvac-demo-conf:
+#     Adds configuration to make agl-service-hvac use sllin0 for its
+#     HVAC board control via CAN -> LIN.
 # - simple-can-simulator:
 #     CAN message simulator for vehicle and engine speed message
 #     generation, with some support for the cruise control events from
@@ -30,5 +33,6 @@ RDEPENDS:${PN} = "\
     demo-i2c-udev-conf \
     sllin-demo \
     kuksa-dbc-feeder-sllin \
+    agl-service-hvac-demo-conf \
     simple-can-simulator \
 "
index d9e691b..7646ccf 100644 (file)
@@ -11,4 +11,5 @@ RDEPENDS:${PN} += "\
     kuksa-val \
     kuksa-val-agl \
     kuksa-dbc-feeder \
+    agl-service-hvac \
     "