Sunday, August 20th 2017, 6:02am UTC+2

You are not logged in.

  • Login
  • Register

Dear visitor, welcome to SEGGER Forum. If this is your first visit here, please read the Help. It explains how this page works. You must be registered before you can use all the page's features. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

mikbeng

Beginner

Date of registration: Feb 13th 2017

Posts: 3

1

Monday, February 13th 2017, 3:14pm

[SOLVED] Global variables are missing in J-Scope

Hello,

I've noticed that most of my global variables are missing in J-scope symbol selector. All my local variables in their corresponding C-file are showing however.

I'm using VisualGDB with arm-eabi gcc compiler for a stm32f4 microcontroller.

I've made sure that the optimization is completely off, i.e CFLAGS and CXXFLAGS set to -O0 in makefile settings.

Don't know what else to check. Any help would be appreciated!

SEGGER - Niklas

Super Moderator

Date of registration: Oct 6th 2014

Posts: 1,568

2

Monday, February 13th 2017, 3:30pm

Hi,

which version of J-Scope do you use?
Would it be possible to provide us with the .elf file so that we can reproduce the issue?

Best regards,
Niklas
Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
Notification for Embedded Studio: Link

mikbeng

Beginner

Date of registration: Feb 13th 2017

Posts: 3

3

Monday, February 13th 2017, 5:29pm

Hi, thanks for the fast response!

I'm using version 5.10d. Attaching the .elf file for a simple example project that shows the problem. mems_visualGDB.zip


What i discovered was that j-scope seems to be unable to see a global variable that is declared in main.h with the extern keyword, then this variable is defined in main.c as follows:

In main.h
extern uint32_t global_cnt;


in main.c
uint32_t global_cnt;

when opening j-scope the variable global_cnt simply does not show up. But maybe this is how it suppose to be?

Regards
Mikael

SEGGER - Arne

Super Moderator

Date of registration: Oct 16th 2015

Posts: 79

4

Tuesday, February 14th 2017, 2:32pm

Hi Mikael,

thanks for the .elf file.

The way, VisualGDB stores declarations of variables which are defined elsewhere, confused J-Scope's .elf file parser.

We have released a new beta version, where this bug should be fixed:
https://www.segger.com/downloads/jlink_beta

Could you please download it and give it a try?

Regards
Arne

mikbeng

Beginner

Date of registration: Feb 13th 2017

Posts: 3

5

Thursday, March 2nd 2017, 3:28pm

Thanks for the info, all works well now with the beta version!

Thank you again!

//Mikael

SEGGER - Niklas

Super Moderator

Date of registration: Oct 6th 2014

Posts: 1,568

6

Friday, March 10th 2017, 10:43am

Hi Mikael,


thanks for the feedback.
Good to hear that you are up and running!


Best regards,
Niklas
Would you like to be added to the J-Link software update notification list, so you get informed automatically when a new version becomes available?
Just write me a PM or in case you want to subscribe to it yourself, please use this link: Link
Notification for J-Link, J-Link Debugger, SystemView & J-Scope: Link
Notification for Embedded Studio: Link