summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--conf/include/agl-demo-preload.inc4
-rw-r--r--recipes-config/dev-mapping-demo/dev-mapping-demo/dev-mapping.conf.demo6
-rw-r--r--recipes-config/dev-mapping-demo/dev-mapping-demo_1.0.bb18
-rw-r--r--templates/feature/agl-demo-preload/50_local.conf.inc3
4 files changed, 30 insertions, 1 deletions
diff --git a/conf/include/agl-demo-preload.inc b/conf/include/agl-demo-preload.inc
new file mode 100644
index 000000000..a17d1403e
--- /dev/null
+++ b/conf/include/agl-demo-preload.inc
@@ -0,0 +1,4 @@
+DISTRO_FEATURES_append = " agl-demo-preload"
+
+# Use demo device mapping for low-can that enables sllin0
+PREFERRED_RPROVIDER_virtual/low-can-dev-mapping = "dev-mapping-demo"
diff --git a/recipes-config/dev-mapping-demo/dev-mapping-demo/dev-mapping.conf.demo b/recipes-config/dev-mapping-demo/dev-mapping-demo/dev-mapping.conf.demo
new file mode 100644
index 000000000..93b0a020b
--- /dev/null
+++ b/recipes-config/dev-mapping-demo/dev-mapping-demo/dev-mapping.conf.demo
@@ -0,0 +1,6 @@
+; Default CAN device mapping
+; Format has to follow ini rules key="value", notice " around value.
+
+[CANbus-mapping]
+hs="can0"
+ls="sllin0"
diff --git a/recipes-config/dev-mapping-demo/dev-mapping-demo_1.0.bb b/recipes-config/dev-mapping-demo/dev-mapping-demo_1.0.bb
new file mode 100644
index 000000000..4a04ce13b
--- /dev/null
+++ b/recipes-config/dev-mapping-demo/dev-mapping-demo_1.0.bb
@@ -0,0 +1,18 @@
+SUMMARY = "AGL demo device mapping configuration file"
+DESCRIPTION = "This provide default dev-mapping.conf file \
+ that defines mapping between kernel device and logical name \
+ used in low-can binding for the AGL demo setup."
+
+LICENSE = "MIT"
+LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
+
+SRC_URI += "file://dev-mapping.conf.demo"
+
+inherit allarch
+
+do_install() {
+ install -d ${D}${sysconfdir}
+ install -m 0644 ${WORKDIR}/dev-mapping.conf.demo ${D}${sysconfdir}/dev-mapping.conf
+}
+
+RPROVIDES_${PN} = "virtual/low-can-dev-mapping"
diff --git a/templates/feature/agl-demo-preload/50_local.conf.inc b/templates/feature/agl-demo-preload/50_local.conf.inc
index c7524e5ae..00ff3b718 100644
--- a/templates/feature/agl-demo-preload/50_local.conf.inc
+++ b/templates/feature/agl-demo-preload/50_local.conf.inc
@@ -1 +1,2 @@
-DISTRO_FEATURES_append = " agl-demo-preload"
+#see meta-agl-demo/conf/include/agl-demo-preload.inc
+require conf/include/agl-demo-preload.inc