2025-11-13 2:20 AM
Hello,
I'm working on a custom STM32H7S7L8 board with this display
https://newhavendisplay.com/fr/2-4-tft-lcd-ips-high-brightness-display/
Here the schematic of the connection in 8 bit mode and clock three
The backlight and display are working but I get a glitch image when i try to fill the display.
with this code i can see the display turning off and on so the command are working
Below the whole project zip
LCD_Fill(0xFFFF, 0, 0, 10, 10);
HAL_Delay(1000);
ST7789H2_DisplayOff();
LCD_Fill(0xFFFF, 0, 0, 10, 10);
HAL_Delay(1000);
ST7789H2_DisplayOn();
Does someone have a idea to make this work
Thanks
2025-11-13 3:26 AM
Hello,
Did you modify this line in MPU config or it was generated by CubeMx:
MPU_InitStruct.SubRegionDisable = 0x0;
Normally it should be 0x87 not 0x0!
2025-11-13 3:28 AM - edited 2025-11-13 3:30 AM
Also these lines?:
MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
MPU_InitStruct.DisableExec = MPU_INSTRUCTION_ACCESS_ENABLE;
2025-11-13 4:14 AM
@mƎALLEm Thanks for the response
It was generated by cube MX to test if the issue was MPU usage but even without the MPU it doesn't work
2025-11-13 4:41 AM
Did you change the default MPU config in CubeMx?
2025-11-13 4:43 AM
Yeah i made the test without MPU and after enabled MPU that give permsission to the whole chip
2025-11-13 5:02 AM - edited 2025-11-13 5:03 AM
You should not modify that MPU region, keep it as is.
You need to add another MPU config for the LCD region and you should disable the cacheability for that region. You need also to enable the cache.