ST STM32CubeH7 User manual

June 2019 UM2222 Rev 2 1/76
1
UM2222
User manual
STM32CubeH7 demonstration platform
Introduction
STM32Cube is an STMicroelectronics original initiative to make developers’ lives easier by
reducing development effort, time and cost. STM32Cube covers the whole STM32 portfolio.
The STM32CubeH7 demonstration platform complements STM32Cube as a firmware
package that offers a full set of software components based on a modular architecture,
separately reusable in standalone applications. The STM32CubeH7 demonstration kernel
manages all these modules, allowing dynamic addition of new modules, and access to
common resources (storage, graphical components and widgets, memory management,
real-time operating system).
The STM32CubeH7 demonstration platform is built around the powerful STemWin graphical
library and the FreeRTOS™ real-time operating system, and uses almost the whole STM32
capability to offer a large scope of usage based on the STM32Cube HAL BSP and several
middleware components.
The architecture uses the STM32CubeH7 demonstration core to make an independent
central component that is usable with several RTOSs and third party firmware libraries
through dedicated abstraction layers inserted between the STM32CubeH7 demonstration
core and the associated modules and libraries.
The STM32CubeH7 demonstration supports STM32H7 Series devices and runs on
STM32H743I-EVAL, STM32H745I-DISCO, STM32H747I EVAL, STM32H747I DISCO and
STM32H747I DISC1 boards.
Pictures are not contractual.
www.st.com

Contents UM2222
2/76 UM2222 Rev 2
Contents
1 STM32Cube overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
2 Global architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
3 Kernel description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
3.2 Kernel initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .11
3.3 Kernel processes and tasks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
3.4 Kernel graphical aspect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
3.5 Kernel menu management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
3.6 Module manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
3.7 Backup and settings configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.8 Storage units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
3.9 Adding binary demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
3.10 Demonstration repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
3.11 Kernel components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3.12 Kernel core files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
3.13 Hardware settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
4 How to create a new module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
4.1 Creating the graphical aspect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
4.2 Graphics customization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
4.3 Module implementation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
4.4 Adding a module to the main desktop . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
5 Demonstration customization and configuration . . . . . . . . . . . . . . . . 27
5.1 LCD configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
5.2 Layer management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
5.3 BSP customization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
5.3.1 SDRAM configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
5.3.2 Touchscreen configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29

UM2222 Rev 2 3/76
UM2222 Contents
4
6 Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
6.1 CPU cache . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
6.2 Multi buffering features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32
6.3 Multi layers feature . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
6.4 Hardware acceleration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
6.5 Hardware JPEG Decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
7 Footprint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
7.1 STemWin features resources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
7.1.1 JPEG decoder . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
7.1.2 GUI components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
8 Functional description of STM32H743I-EVAL,
STM32H747I-EVAL and STM32H747I-DISCO
demonstration modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
8.1 STemWin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
8.1.1 Audio player . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39
8.1.2 Video player . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
8.1.3 Rocket game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
8.1.4 Clock and weather . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
8.1.5 Graphic effect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
8.1.6 Dual core module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
8.1.7 System information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
8.2 TouchGFX demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
8.2.1 Audio player module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
8.2.2 Graphics effect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
8.2.3 Video player module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
8.2.4 Time and calendar module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
8.2.5 Home control module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
8.2.6 Light effect module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
8.2.7 External hardware module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
8.2.8 Bird eat coin . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
8.2.9 Knight hit zombie game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
8.2.10 2048 Puzzle game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
8.3 Embedded wizard demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60

Contents UM2222
4/76 UM2222 Rev 2
8.3.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
8.3.2 Video player module (only H743I-EVAL) . . . . . . . . . . . . . . . . . . . . . . . . 60
8.3.3 Graphic effect module (only H743I-EVAL) . . . . . . . . . . . . . . . . . . . . . . . 61
8.3.4 TapTap plane module (only H743I-EVAL) . . . . . . . . . . . . . . . . . . . . . . . 61
8.3.5 Graphics accelerator module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
8.3.6 Waveform generator module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
8.3.7 Screen saver module (only H743I-EVAL) . . . . . . . . . . . . . . . . . . . . . . . 63
8.3.8 Charts demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
8.3.9 Climate cabinet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
8.3.10 Brick game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
8.3.11 Fitness tracker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
8.3.12 Paper cutter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
8.3.13 Washing machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
9 Functional description of the STM32H745I-DISCO
demonstration modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
9.1 Main graphical interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
9.2 System information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
9.3 EEMBC®CoreMark® . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
9.4 Oscilloscope and signals generator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
9.4.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
9.4.2 Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
9.4.3 Hardware and software setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
9.4.4 How to use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75

UM2222 Rev 2 5/76
UM2222 List of tables
5
List of tables
Table 1. File system interface functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
Table 2. Kernel components list . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Table 3. Kernel core files list. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
Table 4. Jumpers for demonstration boards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Table 5. LCD frame buffer locations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Table 6. Modules footprint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
Table 7. RAM requirements for some JPEG resolutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36
Table 8. MemoSTemWin components memory requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
Table 9. Widget memory requirements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37
Table 10. Audio player module controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43
Table 11. Video player module controls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 46
Table 12. Document revision history . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75

List of figures UM2222
6/76 UM2222 Rev 2
List of figures
Figure 1. STM32Cube block diagram . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
Figure 2. STM32CubeH7 demonstration architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9
Figure 3. Kernel components and services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
Figure 4. Splash screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Figure 5. Demonstrations main menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13
Figure 6. STemWin demonstration main menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
Figure 7. Functionalities and properties of modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
Figure 8. Available storage units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
Figure 9. Software architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Figure 10. Demonstration memory mapping . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19
Figure 11. Demonstration folder structure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21
Figure 12. STM32Cube demonstration boards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23
Figure 13. GUIBuilder overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24
Figure 14. Graphics customization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
Figure 15. LCDConf.c location . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27
Figure 16. SDRAM initialization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
Figure 17. Touch screen configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 29
Figure 18. STM32H7 Series system architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31
Figure 19. Performance of STM32H7 Series versus STM32F7 Series . . . . . . . . . . . . . . . . . . . . . . . . 32
Figure 20. Example of tearing effect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Figure 21. Independent layer management . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33
Figure 22. Hardware JPEG decoding . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35
Figure 23. Audio player module architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Figure 24. Audio player module process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
Figure 25. Audio player module startup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41
Figure 26. Connectivity of audio player module hardware. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
Figure 27. Video player module architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44
Figure 28. Video player module process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Figure 29. Video player module startup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45
Figure 30. Rocket game startup. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
Figure 31. Rocket game ongoing. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
Figure 32. Rocket game end . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Figure 33. Clock and weather startup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Figure 34. Clock and weather module settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
Figure 35. Clock and weather module skins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
Figure 36. Graphic effect main screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49
Figure 37. Dual core module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
Figure 38. System information main screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
Figure 39. TouchGFX demonstration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Figure 40. TouchGFX - Audio player module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51
Figure 41. The three audio menus, playlist (left), directories (middle) and equalizer (right) . . . . . . . . 52
Figure 42. Graphics effect module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52
Figure 43. TouchGFX - Video player module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53
Figure 44. The three video player menus, video player (left), directory (middle) and playlist (right) . . 53
Figure 45. TouchGFX - Time and calendar module. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54
Figure 46. The three settings menus, watch face (left), set time (middle) and set date (right) . . . . . . 54
Figure 47. TouchGFX - Home control module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55
Figure 48. Menu to set the blinds, like light and security but options only to tune on and off . . . . . . . 55

UM2222 Rev 2 7/76
UM2222 List of figures
7
Figure 49. TouchGFX - Light effect module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56
Figure 50. TouchGFX - External hardware module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57
Figure 51. Bird eat coin game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Figure 52. TouchGFX - Knight hit zombie game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58
Figure 53. 2048 Puzzle game module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Figure 54. The How To Play modal window . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59
Figure 55. Embedded wizard demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Figure 56. Embedded wizard - Video player module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
Figure 57. Embedded wizard - Graphic effect module. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Figure 58. Embedded wizard - TapTap plane module. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61
Figure 59. Embedded wizard - Graphics accelerator module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
Figure 60. Embedded wizard - Waveform generator module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 62
Figure 61. Embedded wizard - Screen saver module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Figure 62. Charts demonstration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63
Figure 63. Climate cabinet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Figure 64. Brick game . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64
Figure 65. Fitness tracker . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Figure 66. Paper cutter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 65
Figure 67. Washing machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66
Figure 68. Main menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67
Figure 69. System information module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Figure 70. EEMBC®CoreMark®application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68
Figure 71. Oscilloscope and signals generator application . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69
Figure 72. Oscilloscope and signals generator overview. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71
Figure 73. Signal generator to oscilloscope connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Figure 74. External signal to oscilloscope connection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72
Figure 75. PC oscilloscope screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73
Figure 76. STM32H745I-DISCO board screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73

STM32Cube overview UM2222
8/76 UM2222 Rev 2
1 STM32Cube overview
STM32Cube is an STMicroelectronics original initiative to significantly improve designer's
productivity by reducing development effort, time and cost. STM32Cube covers the whole
STM32 portfolio.
STM32Cube includes:
•A set of user-friendly software development tools to cover project development from
the conception to the realization, among which:
– STM32CubeMX, a graphical software configuration tool that allows the automatic
generation of C initialization code using graphical wizards
•STM32Cube MCU & MPU Packages, comprehensive embedded-software platforms
specific to each microcontroller and microprocessor series (such as STM32CubeH7 for
the STM32H7 Series), which include:
– STM32Cube hardware abstraction layer (HAL), ensuring maximized portability
across the portfolio of STM32 32-bit Arm®(a) Cortex®-based microcontrollers
– A consistent set of middleware components such as RTOS, FAT file system, and
graphics
– All embedded software utilities with full sets of peripheral and applicative
examples
Figure 1. STM32Cube block diagram
a. Arm is a registered trademark of Arm Limited (or its subsidiaries) in the US and/or elsewhere.
06Y9
$SSOLFDWLRQV
6\VWHP
PDQDJHU
,QSXWDQG
+0,PDQDJHU
0RGXOH
PDQDJHU
0HPRU\
PDQDJHU
6WRUDJH
PDQDJHU
'HPRQVWUDWLRQV
5726
)UHH5726
)LOH
V\VWHP
)DW)6
*UDSKLFV
67HP:LQ
67JUDSKLFDO
DGGRQVDQGVNLQV
$XGLRDGGRQV
8WLOLWLHV
&06,6
0LGGOHZDUH
%RDUGVXSSRUWSDFNDJH%63 +DUGZDUHDEVWUDFWLRQOD\HU+$/
'ULYHUV
*UDSKLFV
67HP:LQ
7RXFK*);
(0EHGGHG:L]DUG
7RXFK*);$SSV
67HP:LQ$SSV
(0EHGGHG:L]DUG$SSV

UM2222 Rev 2 9/76
UM2222 Global architecture
75
2 Global architecture
The STM32CubeH7 demonstration is composed of a central kernel based on a set of
firmware and hardware services offered by the STM32Cube middleware, several Evaluation
and Discovery boards, and a set of modules mounted on the kernel and built in a modular
architecture. Each module is separately reusable in a standalone application.
The kernel manages the full set of modules. It provides access to all common resources and
facilitates the addition of new modules as shown in Figure 2.
Each module provides the following functionalities and properties:
•Icon and graphical aspect characteristics
•Method to start up the module
•Method to close down safely the module (such as Hot unplug for unit storage)
•Method to manage low-power modes
•The module application core (main module process)
•Specific configuration
•Error management
Figure 2. STM32CubeH7 demonstration architecture

Kernel description UM2222
10/76 UM2222 Rev 2
3 Kernel description
3.1 Overview
The role of the demonstration kernel is mainly to provide a generic platform that controls
and monitors all the application processes. The kernel provides a set of friendly user APIs
and services, allowing the user modules to benefit from all the hardware and firmware
resources.
The kernel provides the tasks and services listed below:
•Hardware and modules initialization:
– BSP initialization (SDRAM, touch screen, CRC, RTC, Quad-SPI)
– GUI initialization
•Memory management
•Graphical resources and main menu management
•Storage management
•System monitoring and settings
•CPU utilities (CPU usage, running tasks)
Figure 3. Kernel components and services

UM2222 Rev 2 11/76
UM2222 Kernel description
75
3.2 Kernel initialization
The first task of the kernel is to initialize the hardware and firmware resources to make them
available to its internal processes and the modules around it.
The kernel starts by initializing the HAL system clocks, and then the hardware resources
needed by the middleware components:
•Touch screen
•SDRAM
•Quad-SPI Flash memory
•Backup SRAM
•RTC
Once, the low-level resources are initialized, the kernel performs the STemWin GUI library
initialization and prepares the following common services:
•Memory manager
•Storage units
•Modules manager
•Kernel log
Upon full initialization phase, the kernel adds and links the system and user modules to the
demonstration core.

Kernel description UM2222
12/76 UM2222 Rev 2
3.3 Kernel processes and tasks
The kernel is composed of a main task and software timer scheduled by FreeRTOS through
the CMSIS-OS wrapping layer:
•GUI thread: this task initializes the demonstration main menu and then handles the
graphical background task when requested by the STemWin.
•Software timer: managing periodically (each 30 ms) the touch screen state.
Note: For the STM32H747I EVAL and DISCO board demonstrations, the interrupt handles
the touch screen event.

UM2222 Rev 2 13/76
UM2222 Kernel description
75
3.4 Kernel graphical aspect
The graphical aspect of the STM32Cube demonstration is divided into three main graphical
components listed below:
•At the board reset, the splash screen appears for a few seconds. The splash screen
can be skipped by a simple click on the screen, to launch the main menu of the three
demonstrations. In the case of the STM32H747I DISC1 (Discovery board provided
without LCD screen board), the demonstration software ends with blanking the red LED
LD3.
Figure 4. Splash screen
•Start the main menu of each demonstration by clicking on the dedicated icon.
Figure 5. Demonstrations main menu
Note: STemWin, TouchGFX and the source code of the menu launcher are available. The
embedded wizard demonstration is available only with the full binary file.

Kernel description UM2222
14/76 UM2222 Rev 2
3.5 Kernel menu management
Note: Important - This user manual describes all the demonstration modules. STemWin and
TouchGFX modules are detailed as the source code is provided.
The main demonstration menu is initialized and launched by the GUI thread. Before the
initialization of the menu, the following actions are performed:
•Draw the background image.
•Restore general settings from backup memory.
•Setup the main desktop callback to manage main window messages.
The icon view widget contains the icons associated to added modules. The user can launch
a module by a simple click. The user can also slide the icons and select the modules.
Figure 6. STemWin demonstration main menu

UM2222 Rev 2 15/76
UM2222 Kernel description
75
A module is launched with a simple click on the associated icon by calling to the startup
function in the module structure. This is performed when a WM_NOTIFICATION_RELEASED
message arrives to the desktop callback with ID_ICONVIEW_MENU.
3.6 Module manager
The kernel manages the modules. It is responsible of initializing relative hardware and GUI
resources, common resources such as a storage unit, graphical widget and the system
menu.
Figure 7. Functionalities and properties of modules
06Y9
*UDSKLFDO
IRUPV
SURSHUWLHV
'LVWDQW
FRQWURO
%DFNJURXQG
WDVN
&RQILJXUDWLRQ
(UURU
PDQDJHPHQW
/RZSRZHU
PDQDJHPHQW
6DIH
FORVHGRZQ
PRGXOH
,QLWLDOL]DWLRQ
PRGXOH
$SSOLFDWLRQ
WDVN
2SWLRQDOPRGXOHV

Kernel description UM2222
16/76 UM2222 Rev 2
Each module provides the following functionalities and properties:
•Icon and graphical component structure
•Method to startup the module
•Method to close down safely the module (such as Hot unplug for MS flash disk)
•Method to manage low-power modes (optional)
•Application task
•Module background process (optional)
•Remote control method (optional)
•Specific configuration
•Error management
The modules can be added to the demonstration and use the common kernel resources.
The code below shows how to add a module to the demonstration.
A module is a set of function and data structures, which are defined in a global data
structure, and provide all the information and pointers to specific methods and functions to
the kernel. This later checks the integrity and the validity of the module and inserts its
structure into a module table. A unique identifier (UID) identifies each module. When two
modules have the same UID, the kernel rejects the second one.
The module structure is defined as follows:
•id: unique module identifier
•name: pointer to module name
•open_icon: pointer to module icon frames (array of bitmap format moving on the right)
•close_icon: pointer to module icon (array of bitmap format moving on the left)
•startup: the function creating the module frame and control buttons
•DirectOpen: reserved for feature use.

UM2222 Rev 2 17/76
UM2222 Kernel description
75
3.7 Backup and settings configuration
The STM32Cube demonstration saves the kernel and module settings using the following
method:
•Using the RTC backup register (32-bit data width): the data to save must be a 32-bit
data and can be defined as a bit field structure.
•Two kernel APIs are used to save or restore the structure from the RTC backup
registers.
3.8 Storage units
The STM32Cube demonstration kernel offers a storage unit that is usable to retrieve audio,
bitmaps and video media. The storage unit is initialized during the platform startup and thus
it is available to all the modules during the STM32Cube Demonstration run time.
Figure 8. Available storage units
The unit is accessible through the standard I/O operations offered by the FatFS used in the
development platform. The unit is mounted automatically when the physical media is
connected to the connector on the board. Table 1 lists the file system interface functions
(FatFS functions) used to deal with the physical storage unit.

Kernel description UM2222
18/76 UM2222 Rev 2
In the FatFS file system, the page size is fixed to 512 bytes. The SD cards with higher page
size are not supported.
The software architecture of the storage unit is described in Figure 9.
Table 1. File system interface functions
Function Description
disk_initialize Initialize disk drive
disk_read Interface function for a logical page read
disk_write Interface function for a logical page write
disk_status Interface function for testing if unit is ready
disk_ioctl Control device dependent features
f_mount Register / unregister a work area
f_open Open / create a file
f_close Close a file
f_read Read a file
f_write Write a file
f_lseek Move read / write pointer, expand file size
f_truncate Truncate file size
f_sync Flush cached data
f_opendir Open a directory
f_readdir Read a directory item
f_getfree Get free clusters
f_stat Get a file status
f_mkdir Create a directory
f_unlink Remove a file or a directory
f_chmod Change attribute
f_utime Change timestamp
f_rename Rename / move a file or a directory
f_mkfs Create a file system on the drive
f_forward Forward file data to the stream directly
f_chdir Change current directory
f_chdrive Change current drive
f_getcwd Retrieve the current directory
f_gets Read a string
f_putc Write a character
f_puts Write a string
f_printf Write a formatted string

UM2222 Rev 2 19/76
UM2222 Kernel description
75
Figure 9. Software architecture
The FatFS is mounted upon the mass storage to allow an abstract access to the physical
media through standard I/O methods.
3.9 Adding binary demonstration
The user can load a specific demonstration as a binary in a specific memory address. The
specific demonstration is launched during the run-time of the native ST demonstration. The
main demonstration (ST demonstration) jumps to the specific demonstration address. From
the specific demonstration, the user can go back to the main demonstration by doing a
hardware reset.
The specific demonstration must provide a control button named “Menu” that triggers a
hardware reset and saves a specific signature in the backup SRAM.
Figure 10 shows how the main demonstration and the specific demonstration must be
mapped in the memory.
Figure 10. Demonstration memory mapping
06Y9
$SSOLFDWLRQ
)DW)6PRGXOH
*HQHULFORZOHYHOGULYHULQWHUIDFH
+$/GULYHUV
%63GULYHUV
/RZOHYHOGLVN
,2GULYHUV
/LQNPHFKDQLVP
06Y9
[
[
4XDG63,)ODVKPHPRU\
[
[
0DLQGHPRFRGH 0DLQGHPRUHVRXUFHV
6SHFLILFGHPRUHVRXUFHV
,QWHUQDO)ODVKPHPRU\
6SHFLILFGHPRFRGH

Kernel description UM2222
20/76 UM2222 Rev 2
Main demonstration
Upon clicking on the specific demonstration icon in the main menu of the native main
demonstration, a signature A is saved in the backup SRAM and a reset is performed.
During the next start of the ST demonstration, the signature is checked. If the result is A, the
PC jumps to the specific demonstration memory location and the specific demonstration
starts.
Specific demonstration
The specific demonstration must provide a GUI control button named “Menu”. When “menu”
is activated, a signature B is saved in the backup SRAM and a reset is performed.
During the next start, the startup screen is bypassed and the main demonstration menu is
directly shown.
Signature and base address
#define SPECIFC_DEMO_ADDRESS 0x08100000
#define SPECIFC_DEMO_SIGNATURE_A 0x5AA55AAA
#define SPECIFC_DEMO_SIGNATURE_B 0x5AA55BBB
Reset sequence
The reset sequence must be built as follows:
__HAL_RCC_RTC_ENABLE();
__HAL_RCC_PWR_CLK_ENABLE();
__HAL_RCC_BKPSRAM_CLK_ENABLE();
HAL_PWR_EnableBkUpAccess();
(...)
*(uint32_t *)(0x40024000) = SPECIFIC_DEMO_SIGNATURE_B;
NVIC_SystemReset();
In the system_stm32h7xx.c, the specific demonstration must change the vector table offset
define (#define VECT_TAB_OFFSET) to 0x100000. The system_init function then sets the
VTOR (vector table offset register) to the specific demonstration base address
(0x08100000).
Table of contents
Other ST Motherboard manuals

ST
ST STEVAL-IPC002V1 User manual

ST
ST SPC582B-DIS User manual

ST
ST STM32MP157F-EV1 User manual

ST
ST STEVAL-USBPD45H Administrator Guide

ST
ST UM2414 User manual

ST
ST STM32 Nucleo User manual

ST
ST SPC572LADPT80S User manual

ST
ST X-NUCLEO-CCA02M1 User manual

ST
ST NUCLEO-L433RC-P User manual

ST
ST UM2711 User manual

ST
ST STM32091C-EVAL User manual

ST
ST STM3220G-EVAL User manual

ST
ST SPC58XXADPT292S User manual

ST
ST AEK-SNS-2TOFM1 User manual

ST
ST STM32 Nucleo Installation and operating instructions

ST
ST EVAL-TDA7803A User manual

ST
ST NUCLEO-G070RB User manual

ST
ST STEVAL-BLUEPIRV1 User manual

ST
ST STEVAL-TSP009V2 Administrator Guide

ST
ST NUCLEO-H745ZI-Q User manual