Trying to built yocto for fx30 cat1

More than one week for I did try to generate yocto for my FX30 cat1 (Release R16.0.1.006 + Legato 19.11.5)

My first mistake was to try to build with ubuntu 21 : I failed.

Then I decided to use a docker with a ubuntu:18_04 and I is a little better but some issues remain.

I did download the src with the getsrc and it is ok.

But when I jump in swi-linux-src and run make one warning :
meta-columbia-x/meta-columbia-x-cat1/build.sh: line 854: [: =: unary operator expected

Then I run : “ENABLE_DOTA_STANDALONE=false make” and one error (I did have the first time) :
ERROR: No recipes available for:
/home/root/workspaceLegato/swi-linux-src/meta-columbia-x/rootfs/recipes/columbia-initscripts/columbia-initscripts.bbappend

Is the solution do link meta-swi-mdm9x28-fx30 to meta-swi-mdm9x28-wp ?

What the solution to generate for FX30? I want to generate with a system with extra software.

Regards

I did this for FX30-cat-M in ubuntu16, maybe you can follow:

$> leaf setup fx30-catm -p swi-fx30-catm_3.0.0
$> leaf getsrc legato
$> leaf getsrc swi-linux
$> cd swi-linux
$> make MACH=mdm9x28 PROD=fx30

I did try the make with MACH and PROD and I get close the success but no image generated or not in the right place.

expecting :
build_bin/tmp/sysroots/swi-mdm9x28-wp

with PROD=fx30 result in :
build_bin/tmp/sysroots/swi-mdm9x28-fx30

how about ./build_bin/tmp/deploy/images/swi-mdm9x28-wp/

Hello,

running the following command is OK
ENABLE_DOTA_STANDALONE=false LANG=en_US.UTF-8 make PROD=fx30
But after, trying to build, launch my generation and the error is :

 mksys -t wp76xx -i /home/root/workspaceLegato/leaf-data/fx30new/fx30-cat1-legato/interfaces/modemServices serieTcpNetworkSystem.sdef

** ERROR:
/home/root/workspaceLegato/leaf-data/fx30new/fx30-cat1-legato/drivers/spisvc/spisvc.mdef: error: ‘/home/root/workspaceLegato/swi-linux-src/build_bin/tmp/sysroots/swi-mdm9x28-wp/usr/src/kernel’ is not a valid kernel source directory.
Makefile:3: recipe for target ‘all’ failed

Nothing in the sysroots directory…

Any idea on how to generate the linux.cwe for the fx30 cat1?

mksys is for making legato image, but not for linux.cwe

Perhaps your right but I think I follow the natural way to generate my new legato image :

  • I did download the linux sources : leaf getsrc swi-linux,
  • I try to generate linux with the make command in swi-linux-src (need to add PROD=fx30 for a good generation),
  • then process as usual (when leaf getsrc was disabled).

But it did not work.

Xavier

what did you see inside /home/root/workspaceLegato/leaf-data/fx30new/ and /home/root/workspaceLegato/leaf-data/fx30new/fx30-cat1-legato/?
Can you do “ls” and paste here?

Back to try generating full firmware from sources.

I did succeed in generating yocto but when trying to generate my project, it fails as env variables seems not to be correct in leaf :

WP76XX_SYSROOT=/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/sysroots/swi-mdm9x28-wp
LEGATO_TOOLCHAIN_FULL_PREFIX=/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/sysroots/x86_64-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-
LEGATO_SYSROOT=/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/sysroots/swi-mdm9x28-wp
WP76XX_LINUX_IMAGES=/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/deploy/images/swi-mdm9x28-wp
SWI_LINUX_CLONE=/home/legato/workspaceLegato/swi-linux-src
WP76XX_TOOLCHAIN_DIR=/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/sysroots/x86_64-linux/usr/bin/arm-poky-linux-gnueabi

For example, nothing in build_bin/tmp/sysroots . Path for toolchain is not correct. Impossible to generate my project.

All is perfect when disabling sources (getsrc swi-linux --disable).

Regards

You can create another project in vscode to use package swi-fx30-catm_3.0.0 without swi-linux
After that you can see if you can compile application with that project

Hello,
My modem is CAT-1 and i try to generate linux for it.
What i can see is that env variables when setting leaf getsrc swi-linux are wrong. It refers a PROD=wp instead of PROD=fx30 and nothing in build_bin/tmp/sysroots.

What I have done is : MACH=mdm9x28 PROD=wp make

It succeds after hours of compil but it still don’t work.

I did try for profile : swi-fx30-cat1_2.0.0

What can I do for leaf to work?

Oups, I did : MACH=mdm9x28 PROD=fx30 make

Before (I try the second command to see if something changes).

You want to compile legato application or compile the yocto?

Try to generate the firmware including legato and my app with a custom yocto (linux ?) system.

Reading legato doc, it seems like it is possible to get the sources for linux and legato with getsrc but the way to generate in visual code after is not so clear (I can’t find the way). I wonder how the Sierra people can achieve that.

A thanks for the answer, I do appreciate.

Then can you get the yocto source and build the yocto.cwe file?
This should be the first step.

After the you can create another project to include the package, and then build the legato.cwe in leaf shell

I did succeed in producing yocto_wp76xx.4k.cwe when running the makefile in swi-linux-src.

I try to use it in generating the firmware, replacing linux.cwe with yocto_wp76xx.4k.cwe in my Makefile. It generates the spk file.

But I think I made a mistake with my FX30 modem. I try to install the yocto.cwe directly coypiing it to the modem and then updating with update dowload yocto_wp76xx.4k.cwe. It was not a goot idea. The modem is out. Is there a way to recover? i did try the reset button with no success.

Regards

The correct command should be “fwupdate download yocto.cwe”

What port do you see now when connect usb to PC?

See related topic here:

No more USB port when I connect to PC. I did try reset button of the modem but nothing more.
What I have done is :

  • Transert the yocto file in the modem file system,
  • connect the modem with ssh,
  • try to update with update command (not sure I use fwupdate).
    Everithing works correct with lot of ++++++++ , the modem then restart but no more USB connexion now.
    I’ve heard of the ST1 pin on the modem for hardreset ? I did try to open the modem but the screw are incridibly difficult to withdraw.

I think you need to try to boot pin tp1

Hello, I’ve just recover my modem using the tp1 pin.

I did try one more time to flash the spk I have generated with the build of swi-linux-src but It still don’t work.

What I did change in my Makefile is reference for linux.

Original Makefile that works (with getsrc --disabled) :

system :
swicwe -o system_$(LEGATO_TARGET).spk -c
$(WP76XX_MODEM_IMAGES)/9999999_9907152_SWI9X07Y_02.18.05.00_00_GENERIC_002.041_002.spk
$(WP76XX_LINUX_IMAGES)/linux.cwe
legato.cwe

I did replace reference for linux.cwe with :

/home/legato/workspaceLegato/swi-linux-src/build_bin/tmp/deploy/images/swi-mdm9x28-fx30/yocto_wp76xx.4k.cwe1

It is the cwe generated in swi-linux-src.

Where is the mistake.

Regards