All the dualboot logic will be checked in run time.
To do this:
* Include the altboot.src by default in all the images
* Create a post installation script to change the
firmware_download_path in the cloud connector
* Unify the swupdate file descriptor for dual and single boot
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
This commit modifies the cloud connector configuration to use
'remotemanager.digi.com' URL since it does not use certificates for the
connection.
'edp12.devicecloud.com' only allows connections with certificates.
The certificate is downloaded during the first device connection to DRM and
stored in '/etc/ssl/certs' directory inside the 'rootfs' partition.
Following connections must use this certificate.
After a firmware update 'rootfs' partition is re-programmed (standard boot)
or changed to use the corresponding partition of the other block (dual boot). In
any case the certificate downloaded is not available anymore, so the device is
not able to reconnect.
Currently there is no a 'immutable' partition to store the certificate, that is,
a place where the certificate is not removed during a firmware update and can
be used by the cloud connector (similar to the 'data' partition on a ccmp1)
Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
The directory '/etc/ssl/certs' is in the 'rootfs_x' partition for dual boot or
'rootfs' for standard boot. In any case this certificate cannot be used after
updating because it is stored in the other block partition (for dual boot) or
because the whole partition has be re-programmed (for standard boot).
So, after a firmware update the device will not be able to reconnect to DRM
unless the user revokes the certificate.
This commit changes the certificate directory to be '/mnt/data' where 'data'
partition is mounted. This is not erased during a firmware update, so cloud
connector can use the already downloaded certificate and the device is able to
reconnect to DRM.
Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
The partition "environment" is not available in the ccmp15.
The solution suggested is read the "/proc/mounts" and check if
the "rootfs" is "ubifs" mounted.
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
This commit fixes the following build warning with the swupdate v2022.05:
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.boot.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.boot.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.boot.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.boot.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-wayland-ccmp15-dvk.ubifs)
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
According to the Yocto reference manual, we need to specify the package name
override to indicate the package to which the value applies.
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
Cloud Connector opens USER_BUTTON GPIO as an interrupt to listen for rising and
falling edge events and upload them to Remote Manager as data point values.
Having MCA_IO1 as user button and opened by the Cloud Connector (or any other
software) prevents the device to go to sleep when it is not connected (all
MCA GPIOs are wake-up sources when configured as interrupt)
https://onedigi.atlassian.net/browse/DEL-8155
Signed-off-by: Tatiana Leon <Tatiana.Leon@digi.com>
This commit exports the environment variable XDG_RUNTIME_DIR if does not exists
for services that require sharing a pulseaudio instance.
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
Now the cloud connector has all the logic to detect if its
running in a dual_boot system, so it is not needed this anymore.
We need to modify on the fly the path to save the image in a
dualboot system.
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
Use the same name for both firmware update mechanism.
Add a dependency to only add recovery-utils used by the
non dual-boot firmware update system.
Adding this only one binary/script called update-firmware will
be added.
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
- create dualboot.bbclass that
- sets DUALBOOT_ENABLED variable
- defines partition names and function for changing the sw-description
for swupdate
- move files from layer into meta-digi
https://onedigi.atlassian.net/browse/DEL-7962
Signed-off-by: Hector Palacios <hector.palacios@digi.com>
Signed-off-by: Francisco Gil <francisco.gilmartinez@digi.com>
The new ConnectCore demo functionality makes use of some new Python libraries. Add these libraries
as a dependency in the demo recipe.
Signed-off-by: David Escalona <david.escalona@digi.com>
This commit improves the sysinfo script to skip error on platforms that don't
provide some variables.
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
The demo now has a "Play music" feature, which requires pulseaudio to be running in the device.
This commit checks if pulseaudio is running before starting the demo, and starts the service in
the case it is not.
Signed-off-by: David Escalona <david.escalona@digi.com>
The latest ConnectCore demo updates introduced support for audio controls that
use the mpg123 library to manage audio on the device. This commit adds a
runtime dependency for that package.
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
The start/stop script of the service was using "killproc" and "pidofproc" functions from
"/etc/init.d/functions" to find the process PID. These functions rely on "pidof", which does
not work very well with Python scripts. Instead, use "pkill" and "pgrep" which allow to
search the executable in the full command line to retrieve the correct PID with the -f modifier.
Signed-off-by: David Escalona <david.escalona@digi.com>
The library recently added support for Python bindings. This commit
adds support to compile and install these Python bindings using a
new package: 'libdigiapix-python3'.
Signed-off-by: David Escalona <david.escalona@digi.com>
The ConnectCore Demo is launched on startup and starts the web server. Demo can be accessed
by any computer in the LAN by just typing the IP address of the device in the web browser.
Signed-off-by: David Escalona <david.escalona@digi.com>
Signed-off-by: Isaac Hermida <isaac.hermida@digi.com>
Signed-off-by: David Escalona <david.escalona@digi.com>
(cherry picked from commit ccc9211d00dad7be6cb2c2d0cf179a62563e26c6)
Recent improvements in the cloudconnector core added a dependency with the
swupdate library, so this commit adds a build dependency with the
swupdate package.
https://onedigi.atlassian.net/browse/DEL-7903
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
(cherry picked from commit 654ef8686fd3916ae5ad257f72bd41ed2198d958)
This commit fixes the following build warning with the swupdate v2021.11:
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-xxxxxx.boot.ubifs)
WARNING: dey-image-qt-swu-1.0-r0 do_swuimage: Syntax for sha256 changed,
please use $swupdate_get_sha256(dey-image-qt-xxxxxx.ubifs)
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
Recent improvements in the cloudconnector core added a dependency with the
libdigiapix library, so this commit adds a build dependency with the
libdigiapix package.
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>
The common license file GPL-2.0 is now called GPL-2.0-only in poky, so we need
to reflect this name change to avoid errors
Signed-off-by: Gabriel Valcazar <gabriel.valcazar@digi.com>
Since commit 11558352 ("swu-images: add "installed-directly" flag to
sw-description") the swu package images are streamed into the target without
any temporary copy to support devices with low memory available, that forces a
different order according with the swupdate documentation because scripts
should packed before the rest. This means that all the pre, post and shell
scripts will be executed after the images will be installed. This behavior
breaks the current support to mount the cryptorootfs node before install an
encrypted rootfs.
This commit moves the shell script to mount the cryptorootfs node to the
recovery initramfs and modifies the swupdate command line to call the shell
script before the images installation.
https://onedigi.atlassian.net/browse/CC8X-320
Signed-off-by: Arturo Buzarra <arturo.buzarra@digi.com>