2020-02-26 01:28 AM
Hello,
I have a the following problem:
I create a blank UI template for the STM32H7B3I DK with TouchGFX Designer 4.13.0.
Then, I create a small UI consisting of 1 background box, 1 button, 1 image and 3 interactions. The behavior of the interactions is that when the button is pushed, interaction1 hides image 1, then interaction2 waits 1000ms and then interaction3 shows image1 again.
This works basically. However, after some time (can be minutes, can be seconds), the UI hangs and the button is not responsive anymore. I debugged the application with STM32CubeIDE and found that the software hangs in the following function at line 8 "configASSERT(0);" :
bool STM32TouchController::sampleTouch(int32_t& x, int32_t& y)
{
TS_State_t TS_State = { 0 };
/* This should never fail !! */
if (BSP_TS_GetState(0, &TS_State) != BSP_ERROR_NONE)
{
configASSERT(0);
}
if (TS_State.TouchDetected)
{
x = TS_State.TouchX;
y = TS_State.TouchY;
return true;
}
return false;
}
I tried 2 different ways of loading the application to the board: directly with TouchGFX Designer and with STM32CubeIDE. The behavior is the same for both ways.
I did not change anything in the software, it is generated like this by TouchGFX Designer.
I attached my test application to this message.
Has anybody experienced a similar situation or does anybody have a clue what is going wrong here?
Thank you very much in advance for your help. If you need more information, just ask.
Solved! Go to Solution.
2020-03-25 02:47 AM
Hi Thorsten,
i've got an e-mail from ST with this hint:
Change in main.c:
(...)
void SystemClock_Config(void)
{
RCC_OscInitTypeDef RCC_OscInitStruct = {0};
RCC_ClkInitTypeDef RCC_ClkInitStruct = {0};
RCC_PeriphCLKInitTypeDef PeriphClkInitStruct = {0};
/** Supply configuration update enable
*/
HAL_PWREx_ConfigSupply(PWR_DIRECT_SMPS_SUPPLY);
/** Configure the main internal regulator output voltage
*/
-> __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE0);
(...)
For me it works!
2020-03-20 07:30 AM
Hi TStum
i tried your TestCase but my screen is blank after programming through GFXDesigner.
This happens also if i program an UI Template for the STM32H7B3I-DK.
Do you made some special settings or switch/jumper positions?
Thanks
Volker
2020-03-20 08:18 AM
Hi Volker
thank you for your message.
I tried my TestCase again, the behavior is the same. It works for a short time, then it freezes.
But I don't gat a blank screen after programming.
I did not make any special settings in CubeMX or anywhere else in TouchGFX or CubeIDE.
My switch/jumper position is also default (I guess):
SW1 to FLASH
JP1 set to STLK
JP2 set
Did you use the latest version of TouchGFX Designer and CubeProgrammer?
Thanks
Thorsten
2020-03-21 02:20 AM
Hi Thorsten,
i use the latest Version of all Cube Tools.
I downloaded them last week and installed them at their default path.
My settings are the same.
If i program the demo binary from ST it works.
There must be a little diffierence...
Not a good start with ST :(
2020-03-21 02:21 AM
Can you give me a compiled hex file from your project to test it?
2020-03-23 05:46 AM
2020-03-23 06:08 AM
Hi Thorsten
i got a black screen :(
I become this Messages from the Programmer:
14:06:08 : Memory Programming ...
14:06:08 : Opening and parsing file: STM32H7B3I_DISCO.hex
14:06:08 : File : STM32H7B3I_DISCO.hex
14:06:08 : Size : 1066676 Bytes
14:06:08 : Address : 0x08000000
14:06:08 : Erasing memory corresponding to segment 0:
14:06:08 : Erasing internal memory sectors [0 16]
14:06:08 : Erasing memory corresponding to segment 1:
14:06:08 : Erasing memory corresponding to segment 2:
14:06:08 : Erasing external memory sectors [0 2]
14:06:09 : Download in Progress:
14:06:10 : File download complete
14:06:10 : Time elapsed during download operation: 00:00:02.496
14:06:10 : Verifying ...
14:06:10 : Read progress:
14:06:12 : Download verified successfully
Is this right?
2020-03-23 06:46 AM
Hi Volker,
yes, the messages are identical to mine except the verifying process which I did not select.
Have you tried to push the "disconnect" button in CubeProgrammer after flashing and pushing the RESET button on the board? Depending on the connection mode, the board is resetted when connected with CubeProgrammer.
2020-03-23 06:57 AM
I tried both, powercycle and reset button.
If the demo hex file wouldn't work i would say that the Board is faulty but the demo works fine.
2020-03-23 07:38 AM
Then I don't have another idea, sorry.
Maybe somebody with more knowledge of this board could help us find a way.
For now, with this unsolved behavior, I cannot proceed using this board for our purposes, unfortunately.