I can't access to model from one concrete view.
Hi all
First of all I'm working with STM32F469I-DISCO board and I'm using TouchGFX Designer- 4.15.0.
I have the next problem
My application have 4 different screens, I'm storing in the model general information, and I can access to it without any problem in three of this screen but in one of them I can't.
I've been using the same code and even trying to access at the same data stored in the model but has been impossible.
In this screen the program crash but not in the view but in the presenter, the next is the sequence of my problem:
First step:
Here as you can see below, I'm in a view trying to get _ptr_system from model, so I call to presenter->getsystem();
ScreenSetSubsystemView::ScreenSetSubsystemView() :
scrollListSubsystemSelectedCallback(this, &ScreenSetSubsystemView::scrollListSubsystemSelectedHandler),
_ptr_system (0)
{
touchgfx_printf("\n\nEntrando: Constructor clase ScreenSetSubsystemView\n");
touchgfx_printf("ScreenSetSubsystemView.cpp ScreenSetSubsystemView(): Befor asking _ptr_system to model\n");
_ptr_system = presenter->getsystem();
Second step:
As you can see here, I'm in presenter and I'm trying to access to model->getsystem(), and this the point where problem begin. I can see the touchgfx_printf message but then then program crash.
CSystem* ScreenSetSubsystemPresenter::getsystem() {
touchgfx_printf("ScreenSetSubsystemPresenter::getsystem(): While asking _ptr_system to model\n");
return model->getsystem();
}
And last, I'm in model where I'm trying to get _ptr_system
CSystem* Model::getsystem() {
touchgfx_printf("Model::getsystem(): Returning _ptr_system from model\n");
return _ptr_system;
}
The strange is that I can get for this information without problem through the rest of screens, but not in ScreenSetSubsystemView.cpp
Any idea about of this problem?
Thank you very much for your help.
Regards
Francisco García
