cancel
Showing results for 
Search instead for 
Did you mean: 

Where is Code editor in TouchGFX also where is output window to know errors generated? Run failed for me, where to check for errors?

ABeck.1
Associate II

I am new to TouchGFX. I am working on STM32 controller based project. In that TFT LCD screen is one of the peripherals. I want to create screens using TouchGFX so that i can set value on screen and run timer according to the value entered on screen, during this complete duration my led will be ON

25 REPLIES 25

If it's a custom container then you just implement your setter/getter functions in the Custom Container that you will call from your screenView and do the model presenter scheme.

You can do whatever you want in your custom container. It's a custom container so that's all yours.

/Alexandre

Thanks @Alexandre RENOUX​ .

I am able to do that functionality via what you have said.

I just don't find any items or functions for displaying date like digital clock?

If you don't want to use the digital clock you can simply create your own Text Area where the time is incremented every second. Usually it's better to create a Custom Container for that. There's no function or item to do so, except the digital clock. But it is fairly easy to implement.

Otherwise, sorry but I don't understand your question. Could you be more precise ?

/Alexandre

Okay. I am currently trying with TextArea only.

Basically I want to display Date also with current time. So for displaying date I will use TextArea with wildcraft.

Hi,

I've included into every screen a custom container ( called "TopBar" ) that is in charge to show the time and other system icons .

The new custom container has the handleTickEvent() enabled, call every second a HAL_RTC_GetTime function and update some text field.

Also should update all the system icons and other filed commons to all your screens menus.

To enable the handleTickEvent() function You have to initialize it manually into the main initialize() function

void TopBar::initialize()

{

TopBarBase::initialize();

  Application::getInstance()->registerTimerWidget(this);

}

void TopBar::handleTickEvent()

{

if(HAL_GetTick()-tick_global>1000)

    {

      Update_date_and_time();

      update_icons();

show_alarm();

}

}

regards.

@ChintanParmar​ @Alexandre RENOUX​ 

Thank you already for the code provided. I'm trying to do the exact same thing but unlike Chintan, I didn't manage to make the functionality work (model/presenter/custom container passing of values). I have the values in the screen but I can't pass it to my digital clock + at the ending of the screen, return the values to the screen (from screen to model at the teardown I get it). And if I try to update my value of the clock in the screen, it doesn't want me to because it's protected (normal).

Do you still have the code you used to manage that Chintan?

Thanks in advance.