cancel
Showing results for 
Search instead for 
Did you mean: 

STM-Studio Import Variables fails

AlbertoGarlassi
Associate III

Hello, after selecting the .elf file I get hundred of messages of this type:

GDB Cmd [print /x & arm_cfft_sR_f32_len128.pTwiddle] failed

Error: Address of symbol "arm_cfft_sR_f32_len128" is unknown

and similar, all related to CMSIS.

After I ack all of these errors the import restarts with the same errors, only way out is by killing the program via process manager.

All OK when variable addresses taken from .map are inserted, big pain but OK.

What can be done?

I'm aware of STMCubeMonitor, tried it but it looks like it's a joke, or at least not what I need. I just need a scope and a table to read and write variables. AFAIK CubeMonitor does not even have vertical scale adjust, just to mention the first showstopper.

I'm shure that 99% of people share my needs.

BTW STMCubeMonitor could conveniently be replaced with a binding to Python or whatever, then everybody chooses his own gui, framework etc.

1 ACCEPTED SOLUTION

Accepted Solutions
Wasilewski.Piotr
Associate III

Hey,

So in the first step I import the elf file like it should be done - using the popup (and i get a lot od errors which I close manually - you have to be careful because holding enter key may be too fast and you'll end up on another batch of errors since enter also confirms the elf file you've selected). When the file is already saved in the project you can just add a new variable like I've mentioned previously.

If you'd like you can send me the elf file and I can try to import a variable on my setup 🙂

View solution in original post

20 REPLIES 20
AlbertoGarlassi
Associate III

Seems like the snapshot acquisition mode in STMStudio does not work anymore.

_FAR_DATA amd _NEAR_DATA_ are not defined. Defined as blank, just to proceed.

In .map file there is no g_traceHeader.startMark[0]. There is g_traceHeader but its address is rejected because it is out of range.

Looks like STMStudio is abandoned, hope not, because it shines compared to STMCubeMonitor, and this says it all.

Wasilewski.Piotr
Associate III

Hey,

I struggled with CubeMonitor for some while as I'm moving from C to C++ in one project. I was really disappointed when it turned out STMStudio does not support adding class members to the variable list, and it only sees the class objects. Cube Monitor is so useless I even thought of using a custom script to look for a variable address using gdb and automatically switching them in the STMStudio project config files. However it turned out I don't have to - you can simply place a new variable, manually add its name (for example classInstance.filed), and although it wont show up on the import variable list window, when you click update the address will be found just fine (and later will be updated when it changes during sw development).

0693W00000WLFbRQAX.png 

This actually solves two problems - inability to work with C++ members and the error storm that happens when you try to add variable using the import variable popup.

Hope this helps, and someday ST revisits STMstudio project. In my field (motor control) its the best debug tool there is.

I will give it a try, thanks.

I totally agree with you about the importance of a monitor/scope/data injection//data logger/data export tool. Only reason I can think for its absence is the Arduino printf debugging attitude of some people that does not know the development tools available for decades. Marketing convinced them about the beauty of a dumbed dow experience, and these are the results.

FWIW the best I am using is Micrium UC/Probe, than Freemaster, both offered for free from other suppliers. Without tools like these I'm sorry but I can't think I would start a new project.

AlbertoGarlassi
Associate III

Hello Piotr,

Unfortunately your method does not work for me. It seems you are able to get past the executable file selection step. This is not my case, it seems that there is something odd with the symbol table for CMSIS symbols.

Maybe there is some linker option that takes care of this. And there are tools for .elf inspection.

But I simply give up in dispair. I will resolve the addresses by hand, like it was 1980.

Can't understand why they get the symbols from the .elf instead of the .map.

Probably because .MAP files are very linker/version dependent, while the .ELF is better established, consistent, and potentially carries other meta-data.

But yes having something that can parse ASCII tables would be easier to fix or script.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Wasilewski.Piotr
Associate III

Hey,

So in the first step I import the elf file like it should be done - using the popup (and i get a lot od errors which I close manually - you have to be careful because holding enter key may be too fast and you'll end up on another batch of errors since enter also confirms the elf file you've selected). When the file is already saved in the project you can just add a new variable like I've mentioned previously.

If you'd like you can send me the elf file and I can try to import a variable on my setup 🙂

You are right, it works! Thanks a lot. It is better to click with the mouse button instead of the enter key to avoid restarting the import.

A big step forward, thanks again.

Alberto

Yes, very true. I mentioned it because a competitor has the .map option.

The problem I have, and other, like the need for a 32 bit Java RE, does not come from .elf but from the lack of any update to STMStudio.

Wasilewski.Piotr
Associate III

Hello,

After some time I got fed up with STMStudio and decided to prepare my own tool. If any of you would be interested in trying it out and testing it I'd be grateful for any feedback. Currently it's quite limited when it comes to features, but it's a solid tool for basic real-time debugging.