Integration with AirVantage 1.19 / RPI / SLQS04.00.16.bin.tar.gz


#1

Long Story short … The QMI SDK Guide - Integration with Airvantage V. 1.19 states

Deploy to Raspberry Pi
6.1. Build
6.1.1. Configure toolchain
cd ~
git clone https://github.com/raspberrypi/tools.git
6.1.2. Compile QMI SDK
cd <SDK_ROOT_FOLDER>
make -C pkgs -f pkgs.mak complete -j CPU=rpi
6.1.3. Compile the AirVantage Connector
(cd SampleApps/AirVantageAgent; ./build_avagent.sh rpi)
6.2. Deploy
6.2.1. Copy SDK executables & AirVantage Connector
runtime
scp -r pkgs/qa/qatestrpi build/bin/rpi/slqssdk
SampleApps/AirVantageAgent/build.rpi/runtime pi:/tmp
6.2.2. Start the AirVantage Connector
ssh pi
cd /tmp
sudo ./slqssdk &
sudo ./runtime/start.sh

So… the result is this

[100%] Generating …/…/runtime/lua/agent/system.lua
[100%] Generating …/…/runtime/lua/agent/boot.lua
[100%] Built target agent_modules
Scanning dependencies of target agent
[100%] Built target agent
Scanning dependencies of target mihini
[100%] Built target mihini
cp: cannot stat ‘…/…/build/bin/rpi/libfwupdate.so’: No such file or directory
[ 0%] Built target lib_luasignal
[100%] Built target lib_pointerlist
Scanning dependencies of target lib_extvars
[100%] Building C object agent/agent/treemgr/handlers/extvars/CMakeFiles/lib_extvars.dir/extvars.c.o
[100%] Linking C shared library …/…/…/…/…/runtime/lib/libextvars.so
[100%] Built target lib_extvars
Scanning dependencies of target devtree2
[100%] Building C object non-free/porting/devtree_v2/CMakeFiles/devtree2.dir/devtree2_adapter.c.o
[100%] Linking C shared module …/…/…/runtime/lua/agent/devman/extvars/devtree2.so
[100%] Built target devtree2
Scanning dependencies of target devtree2_install
[100%] Built target devtree2_install
[ 12%] Built target lib_pointerlist
[ 12%] Built target Swi_DSet
[ 12%] Built target Emp
[ 12%] Built target lib_swi_log
[ 25%] Built target lib_yajl
[ 25%] Built target Swi_AirVantage
[ 87%] Built target lualib
Scanning dependencies of target slqs_fw_update
[100%] Building C object cfwk/airvantage/CMakeFiles/slqs_fw_update.dir/slqs_fw_update.c.o
[100%] Linking C executable …/…/runtime/bin/slqs_fw_update
/home/dingo/tools/arm-bcm2708/gcc-linaro-arm-linux-gnueabihf-raspbian-x64/bin/…/lib/gcc/arm-linux-gnueabihf/4.8.3/…/…/…/…/arm-linux-gnueabihf/bin/ld: cannot find -lfwupdate
collect2: error: ld returned 1 exit status
make[3]: *** [cfwk/airvantage/CMakeFiles/slqs_fw_update.dir/build.make:91: runtime/bin/slqs_fw_update] Error 1
make[2]: *** [CMakeFiles/Makefile2:5588: cfwk/airvantage/CMakeFiles/slqs_fw_update.dir/all] Error 2
make[1]: *** [CMakeFiles/Makefile2:5600: cfwk/airvantage/CMakeFiles/slqs_fw_update.dir/rule] Error 2
make: *** [Makefile:1652: slqs_fw_update] Error 2
build.rpi failed

Any clues or insights as to why it would be failing here?


#2

Okay research said ln -s arm rpi in both bin and lib, got it to build now… however on the device itself im seeing this…
So im curious now… being we all know the docs are wrong in places and i dont have the source to libfwupdate and libdevicetree, am i facing maybe an EABIT version incompatibility ? EABI4 vs EABI5 on rasbian ? I was told this worked on Raspbian but dont see how its possible if it cant load libs properly

sudo ./slqssdk &
[1] 1222
pi@raspberrypi:/tmp sudo ./runtime/start.sh pi@raspberrypi:/tmp bin/slqs_fw_update: error while loading shared libraries: libfwupdate.so: cannot open shared object file: No such file or directory
2018-09-24 03:50:41 GENERAL-INFO: ************************************************************
2018-09-24 03:50:41 GENERAL-INFO: Starting ReadyAgent …
2018-09-24 03:50:41 GENERAL-INFO: ReadyAgent: 8.0 - Build: 70cb0cf
2018-09-24 03:50:41 GENERAL-INFO: Lua VM: Lua 5.1.4 (+meta pairs/ipairs) (+patch-lua-5.1.4-3)
2018-09-24 03:50:41 GENERAL-INFO: System: Linux raspberrypi 4.14.70+ #1144 Tue Sep 18 17:20:50 BST 2018 armv6l
2018-09-24 03:50:41 GENERAL-INFO: ************************************************************
In thread: 0x94ad90: error: Failed to open libdevtree.so.2 [libdevtree.so.2: cannot open shared object file: No such file or directory]
stack traceback:
[C]: ?
[C]: in function ‘require’
./lua/agent/treemgr/init.lua:378: in function ‘get_handler’
./lua/agent/treemgr/init.lua:418: in function ‘lpath2hpath’
./lua/agent/treemgr/init.lua:492: in function ‘get_lpath’
./lua/agent/treemgr/init.lua:529: in function <./lua/agent/treemgr/init.lua:477>
(tail call): ?
./lua/agent/init.lua:273: in function <./lua/agent/init.lua:268>

pi@raspberrypi:/tmp ldd runtime/bin/slqs_fw_update /usr/lib/arm-linux-gnueabihf/libarmmem.so (0xb6f57000) libSwi_AirVantage.so => /lib/arm-linux-gnueabihf/libSwi_AirVantage.so (0xb6f47000) libSwi_log.so => /lib/arm-linux-gnueabihf/libSwi_log.so (0xb6f3d000) liblualib.so => /lib/arm-linux-gnueabihf/liblualib.so (0xb6f08000) libfwupdate.so => not found libEmp.so => /lib/arm-linux-gnueabihf/libEmp.so (0xb6efd000) libSwi_DSet.so => /lib/arm-linux-gnueabihf/libSwi_DSet.so (0xb6ef3000) libpthread.so.0 => /lib/arm-linux-gnueabihf/libpthread.so.0 (0xb6eca000) libyajl.so => /lib/arm-linux-gnueabihf/libyajl.so (0xb6eba000) libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0xb6ea7000) libm.so.6 => /lib/arm-linux-gnueabihf/libm.so.6 (0xb6e28000) libc.so.6 => /lib/arm-linux-gnueabihf/libc.so.6 (0xb6ce9000) /lib/ld-linux-armhf.so.3 (0xb6f6d000) pi@raspberrypi:/tmp ldd runtime/lib/libdevtree.so.2
not a dynamic executable
pi@raspberrypi:/tmp file runtime/lib/libdevtree.so.2 runtime/lib/libdevtree.so.2: ELF 32-bit LSB shared object, ARM, EABI4 version 1 (SYSV), dynamically linked, not stripped pi@raspberrypi:/tmp file runtime/lib/libfwupdate.so
runtime/lib/libfwupdate.so: ELF 32-bit LSB shared object, ARM, EABI4 version 1 (SYSV), dynamically linked, not stripped
pi@raspberrypi:/tmp file runtime/lib/lib libbysant_lua.so libdevtree.so.2 libextvars.so libkeystore.so libstagedb.so libSwi_DeviceTree.so libSwi_log.so libSwi_System.so libSwi_Util.so libtommath.so libbysant.so libEmp.so libfwupdate.so liblualib.so libSwi_AirVantage.so libSwi_DSet.so libSwi_Sms.so libSwi_Update.so libtomcrypt.so libyajl.so pi@raspberrypi:/tmp file runtime/lib/libbysant.so
runtime/lib/libbysant.so: ELF 32-bit LSB shared object, ARM, EABI5 version 1 (SYSV), dynamically linked, BuildID[sha1]=031de0e99c58052539c8e929a97c0e5dd7e74364, not stripped
pi@raspberrypi:/tmp ls -al runtime/lib/ total 15668 drwxrwxr-x 2 pi pi 4096 Sep 24 03:49 . drwxrwxr-x 9 pi pi 4096 Sep 24 03:47 .. -rwxr-xr-x 1 pi pi 17547 Sep 24 03:45 libEmp.so -rwxr-xr-x 1 pi pi 33456 Sep 24 03:45 libSwi_AirVantage.so -rwxr-xr-x 1 pi pi 13504 Sep 24 03:45 libSwi_DSet.so -rwxr-xr-x 1 pi pi 20154 Sep 24 03:45 libSwi_DeviceTree.so -rwxr-xr-x 1 pi pi 13040 Sep 24 03:45 libSwi_Sms.so -rwxr-xr-x 1 pi pi 7455 Sep 24 03:45 libSwi_System.so -rwxr-xr-x 1 pi pi 9666 Sep 24 03:45 libSwi_Update.so -rwxr-xr-x 1 pi pi 20206 Sep 24 03:45 libSwi_Util.so -rwxr-xr-x 1 pi pi 11499 Sep 24 03:45 libSwi_log.so -rwxr-xr-x 1 pi pi 30706 Sep 24 03:45 libbysant.so -rwxr-xr-x 1 pi pi 26421 Sep 24 03:45 libbysant_lua.so -rwxr-xr-x 1 pi pi 7657257 Sep 24 03:46 libdevtree.so.2 -rwxr-xr-x 1 pi pi 18185 Sep 24 03:45 libextvars.so -rwxr-xr-x 1 pi pi 7666342 Sep 24 03:45 libfwupdate.so -rwxr-xr-x 1 pi pi 10241 Sep 24 03:45 libkeystore.so -rwxr-xr-x 1 pi pi 163454 Sep 24 03:45 liblualib.so -rwxr-xr-x 1 pi pi 27381 Sep 24 03:45 libstagedb.so -rwxr-xr-x 1 pi pi 150604 Sep 24 03:45 libtomcrypt.so -rwxr-xr-x 1 pi pi 62028 Sep 24 03:45 libtommath.so -rwxr-xr-x 1 pi pi 37219 Sep 24 03:45 libyajl.so pi@raspberrypi:/tmp uname -a
Linux raspberrypi 4.14.70+ #1144 Tue Sep 18 17:20:50 BST 2018 armv6l GNU/Linux


#3

Can you specify the modem you are trying to test with Airvantage?


#4

its a Raspberry PI Zero with a 7304 modem


#5

I was hoping that you were using an MC7455, which has a built in Airvantage solution.
Unfortunately external/SDK Airvantage doesn’t really work with the MC73xx.
We had a proof of concept for the x86, but it was not too stable for commercial use.
We should probably pull it from the docs.


#6

So being that the modem is an MC7304 its pretty much not worth the effort asking for the SDK sources for libfwupdate and libdevtree as your statement is that AirVantage wouldnt really suffice on this modem even if the libraries were built properly for the architecture? And yes I already have an NDA with sierra


#7

Local FW upgrade is working well with the SDK or SDK lite.
But I do not recommend integrating the SDK’s AirVantage extension.
MC74xx has a build in reliable AirVantage engine.


#8

not sure how one can claim local firmware upgrade is working well on arm 32bit… raspberry pi 0 when you cant even load libfwupdate or libdevtree on raspbian, the agent seem to load and run but if you look at the above error messages

pi@raspberrypi:/tmp sudo ./runtime/start.sh pi@raspberrypi:/tmp bin/slqs_fw_update: error while loading shared libraries: libfwupdate.so: cannot open shared object file: No such file or directory

i doont see how it could be working, which is why i inquired about getting sources to those two libraries so i could compile them natively

and well the MC7304 spoecs stated airvantage tested certified… so what gives… very confusing and frustrating

other ideas are MQTT paho against airvantage


#9

If you just want to upgrade the FW on the local filesystem use SDK Lite.
It is a standalone utility : /SampleApps/lite-fw-download.
Actually I’d recommend SDK Lite over SLQSSDK for all projects because it is a library, much simpler to work with.