Loading...
 

Zephyr project on STM32

   Zephyr Workbench, a VSCode extension to manage Zephyr on STM32.
It enables users to easily create, develop, and debug Zephyr applications.
Main features:
  • Install host dependencies.
  • Import toolchain and SDK.
  • Create, configure, build and manage apps.
  • Debug STM32.
You can directly download it from the VSCode marketplace
For more details, visit the Zephyr Workbench

System Workbench for STM32


Linux: Import source file in AC6 use weird directory structure

I had a working project (Coocox) on a STM32Fxx M0 core, but needed a low power version. Seen that CubeMx has export option to AC6, and the export to Coocox took some time, I decided to try AC6 on Linux, using a M3 low power device.

The new device CubeMX export worked and I could compile and debug on linux (the minimal imported)
Then I decided to ‘add’ import my original source code.

I used the wiki and it does import the source code, but the source code is placed in

/home/gerrie/arm_projects/lp_fuel_gauge/SW4STM32/lp_fuel_gauge Configuration/Application/User
say this is DirA.

however main.c is in

/home/gerrie/arm_projects/lp_fuel_gauge/Src ?
Reference this as DirB

I tried some option, and some place the source code in the DirB (were I wants it), but ac6 keep making copies and compile the source in DirA. It weird that you edit a file in the project tab, but the ‘original’ file got compiled DirA, but you change the contence in DirB.

Now the path to include files in main.c wrong, (but displayed as if it is in same Src directory, (but is not)).

The problem is that the CubeMx have the dreaded ‘space’ in the directory (” Configuration/”), and Linux just ‘hates’ spaces.. with lots of problematic issues.

How can I ‘fix’ this, so that my source files location is as displayed in the ‘Project Explorer’ tab?

(Note I could not use the copy and past, or move on Linux, and used the long import
Project Explorer
Application
User
( right click)
Import
File System
untick (Overide)
untick (top level folder)
)
Note: I did remove the space+ Configuration in the Build Artifact (name))

Thanks

You may not change and move files via your Linux file manager while you are working in Eclipse.

You cannot start editing files with gedit or any other text editor while your project is open in Eclipse.

Work from Eclipse and no where else.

The file tree in Eclipse does not necessary equate the directory structure in your file system. Please be aware of this.

As a beginner always have your libraries copied inside your project, thus NOT as external libraries or references. Later on, when you get used to dependencies these can be referenced instead.

You seem to have a funny Linux. ‘Linux being difficult about empty spaces’, I never heard of this before.

Good luck!

Greets,
Ben