2017-11-14 01:33 PM
Hi !
Using STM Studio with my current project gives me 2 errors while loading the elf file:
Seems to be parsing problem of the used gdb.exe tool.
As a result the provided symbol list is very small ...
2018-03-06 09:56 AM
Hello,
The STMStudio allows to select variables from elf file provided they are static (address is known at link time). Your elf file seems to contain few of such variables. You can have an idea of what STMStudio is parsing by running the following sequence (from STMStudio/dll, assuming you also copy your elf file there):
gdb.exe -stmstudio
symbol-file EnginesF4.elf
info variables
The displayed errors are due to an unexpected case in the line:
const bool std::_Function_base::_Base_manager<void (*)(unsigned char*, unsigned char)>::__stored_locally;but are not critical and not impacting the overall result of the parsing.
As example for your case, 'leftEngines' is defined as a pointer, the STM Studio is able to display the value of the pointer (known at link time), but not the pointed contents (would be much useful, probably, but unknown at link time). If you know the address of pointed contents (depending on your application runtime), you can manually define variables displaying it (right click + 'New' in 'display variables settings' panel).
2018-03-07 12:33 PM
Thanks for your feedback.
I was not aware of the fact that only static variables can be shown by the tool.
My previous assumption was induced by the error messages - sorry for that.
So I was looking for an other root cause why so many variables are missing.
Most of the modules are programmed in c++ using namespaces.
It seems that variables in namespaces are not supported:
Here is an example (each test variable is used in the code to prevent a deletion due to optimization)
only the variable outside the namespace is available:
2018-03-08 02:11 AM
You are right, I confirm there is also an issue with C++ namespaces. See also
https://community.st.com/0D50X00009XkYHESA3
In the elf file you posted, I mainly saw const variables defined this way, for which gdb is not able to find an address; so I'm even wondering how the linker is managing them ? Do they appear in the map file ? They are perhaps embedded in the code itself (where used), without any address information in the elf file.
2018-03-08 01:24 PM
Don't know exactly to which variables you refer to. I've attached the current elf+map file for further investigation if needed.
It sounds good that you are working on a new version ...
________________ Attachments : Elf_Map.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006Hxur&d=%2Fa%2F0X0000000b29%2FFLPRDJuqi2FxWfXI5FGNdMPRgTZoBB7dkJOKs6BQ72k&asPdf=false