ST STM32CubeF4 User Manual
ST STM32CubeF4 User Manual

ST STM32CubeF4 User Manual

Demonstration platform
Table of Contents

Advertisement

Quick Links

UM1743
User manual
STM32CubeF4 demonstration platform
Introduction
The STM32Cube initiative was originated by STMicroelectronics to ease developers' life by
reducing development efforts, time and cost. STM32Cube covers the STM32 portfolio.
The STM32CubeF4 demonstration platform comes on top of the STM32Cube as a firmware
package that offers a full set of software components based on a modules architecture that
makes it possible to re-use them separately in standalone applications.
All these modules are managed by the STM32CubeF4 demonstration kernel, with the
possibility of dynamically add new modules and access the common resources (storage,
graphical components and widgets, memory management, Real-Time operating system).
The STM32CubeF4 demonstration platform is built around the powerful graphical library
STemWin and the FreeRTOS real time operating system. It 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 is defined with the goal of making from the STM32CubeF4 demonstration
core an independent central component that can be used with several RTOS and third party
firmware libraries, through several abstraction layers inserted between the STM32CubeF4
demonstration core and the modules and libraries working around it.
The STM32CubeF4 demonstration platform supports STM32F4xx devices and runs on
STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discovery, STM32446E-EVAL,
STM32F479I-EVAL, STM32F469I-DISCO and STM32F412G-Discovery boards.
July 2016
DocID026161 Rev 4
1/111
www.st.com

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the STM32CubeF4 and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Summary of Contents for ST STM32CubeF4

  • Page 1 The STM32Cube initiative was originated by STMicroelectronics to ease developers’ life by reducing development efforts, time and cost. STM32Cube covers the STM32 portfolio. The STM32CubeF4 demonstration platform comes on top of the STM32Cube as a firmware package that offers a full set of software components based on a modules architecture that makes it possible to re-use them separately in standalone applications.
  • Page 2: Table Of Contents

    ST animated icon view ........
  • Page 3 UM1743 Contents LCD configuration ......... . . 40 Layers management .
  • Page 4 Contents UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) ....77 Modules ..........77 9.1.1 Audio .
  • Page 5 UM1743 List of tables List of tables Table 1. File system interface: physical storage control functions ......25 Table 2.
  • Page 6 Figure 26. Memory heap for STM32CubeF4 demonstration ....... . 30 Figure 27.
  • Page 7 UM1743 List of figures Figure 48. File opening from browser ..........58 Figure 49.
  • Page 8 List of figures UM1743 Figure 100. System information ............98 Figure 101.
  • Page 9: Stm32Cube Overview

    A comprehensive embedded software platform, delivered per series (such as STM32CubeF4 for STM32F4 series) – The STM32CubeF4 HAL, an STM32 abstraction layer embedded software, ensuring maximized portability across STM32 portfolio – A consistent set of middleware components such as RTOS, USB, TCP/IP, Graphics –...
  • Page 10: Global Architecture

    UM1743 Global architecture The STM32CubeF4 demonstration is composed of a central kernel based on a set of firmware and hardware services offered by the STM32Cube middleware and the several evaluation and discovery boards and a set of modules mounted on the kernel and built in a modular architecture.
  • Page 11: Kernel Description

    UM1743 Kernel description Kernel description Overview The role of the demonstration kernel is mainly to provide a generic platform that control and monitor all the application processes, the kernel provides a set of friendly user APIs and services that allow to the user modules to have access to all the hardware and firmware resources and provide the following tasks and services: •...
  • Page 12: Kernel Initialization

    Kernel description UM1743 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 during the middleware components: •...
  • Page 13: Kernel Graphical Aspect

    SEGGER emWin one. STemWin is a professional graphical stack library, enabling Graphical User Interfaces (GUI) building up with any STM32, any LCD and any LCD controller, taking benefit from STM32 hardware accelerations, whenever possible. The graphical aspect of the STM32CubeF4 demonstration is divided into two main graphical components: •...
  • Page 14: Figure 5. Startup Window For Stm32446E-Eval , Stm32F479I-Eval

    Kernel description UM1743 Figure 5. Startup window for STM32446E-EVAL , STM32F479I-EVAL, STM32F469I-DISCO and STM32F412G-DISCO demonstrations Figure 6. Main desktop window 14/111 DocID026161 Rev 4...
  • Page 15 UM1743 Kernel description Figure 7. Main desktop window for STM32446E-EVAL demonstration Figure 8. Main desktop window for STM32479I-EVAL demonstration Figure 9. Main desktop window for STM32469I-DISCO demonstration DocID026161 Rev 4 15/111...
  • Page 16: St Widget Add-Ons

    This section is applicable only for STM32F479I-EVAL and STM32F469I-DISCO demonstrations. The ST_addons binary file provided with STM32F4 demonstration contains new widgets based on STemWin graphical library: • ST animated icon view • ST slider skin 3.5.1 ST animated icon view A new icon view widget is delivered with STM32F4 demonstration based on STemWin graphical library.
  • Page 17: St Slider Skin

    UM1743 Kernel description 3.5.2 ST slider skin A new slider skin is delivered with STM32F4 demonstration based on STemWin graphical library. The new skin offers the possibility to change the slider color and the behavior as shown in Figure Figure 12. Slider skin Kernel menu management The main demonstration menu is initialized and launched by the GUI thread.
  • Page 18: Figure 13. Status Bar

    Kernel description UM1743 Figure 13. Status bar Figure 14. Status bar for STM32446E-EVAL demonstration 18/111 DocID026161 Rev 4...
  • Page 19: Figure 15. Icon View Widget

    UM1743 Kernel description Figure 15. Icon view widget Figure 16. Icon view widget for STM32446E-EVAL demonstration A module is launched on simple click on the associated icon by calling to the startup function in the module structure; this is done when a WM_NOTIFICATION_RELEASED message arrives to the desktop callback with ID_ICONVIEW_MENU: DocID026161 Rev 4 19/111...
  • Page 20: Modules Manager

    Kernel description UM1743 Modules manager The modules are managed by the kernel; the latter is responsible of initializing the modules, initializing hardware and GUI resources relative to the modules and initializing the common resources such as the storage Unit, the graphical widgets and the system menu. Each module should provide the following functionalities and proprieties: Icon and graphical component structure.
  • Page 21: Figure 17. Functionalities And Properties Of Modules

    UM1743 Kernel description Figure 17. Functionalities and properties of modules The modules could be added in run time to the demonstration and can use the common kernel resources. The following code shows how to add a module to the demonstration: A module is a set of function and data structures that are defined in a data structure that provides all the information and pointers to specific methods and functions to the kernel.
  • Page 22: Direct Open Feature

    Kernel description UM1743 In this definition: • Id: unique module identifier. • Name: pointer to module name • Icon: pointer to module icon (bitmap format) • Startup: the function that create the module frame and control buttons • DirectOpen: the function that create the module frame and launch the media associated to the file name selected in the file browser linked to a specific file extension (note that this functionality is not used in STM32F479I-EVAL;...
  • Page 23: Backup And Settings Configuration

    Figure 19. Starting file execution for STM32446E-EVAL demonstration Backup and settings configuration The STM32CubeF4 demonstration saves the kernel and modules settings in two different methods: Using the RTC backup register (32 bits data width) , in this method the data to be saved...
  • Page 24: Storage Units

    RAM to save file paths or big structure example: 3.10 Storage units The STM32CubeF4 demonstration kernel offers two storage units that can be used to retrieve audio, Image and Video media or to save captured images from the camera (Figure 20).
  • Page 25: Table 1. File System Interface: Physical Storage Control Functions

    UM1743 Kernel description The implemented functions in the file system interface to deal with the physical storage units are summarized in Table Table 1. File system interface: physical storage control 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...
  • Page 26: Figure 21. Software Architecture

    Kernel description UM1743 Table 2. File system interface APIs (continued) Function Description f_putc Write a character f_puts Write a string f_printf Write a formatted string For the FAT FS file system, the page size is fixed to 512 bytes. USB Flash disks with higher page size are not supported.
  • Page 27: Figure 22. Detection Of Storage Units

    UM1743 Kernel description The storage units' presence detection is handled internally by the kernel and the status bar shows the icons of the available media, as shown in Figure 22 and in Figure Figure 22. Detection of storage units Figure 23. Detection of storage units for STM32446E-EVAL demonstration DocID026161 Rev 4 27/111...
  • Page 28: Clock And Date

    Kernel description UM1743 3.11 Clock and date The clock and date are managed by the RTC HAL driver, the RTC module initializes the LSE source clock and provides a set of methods to retrieve date and clock in addition to backup save and restore ones.
  • Page 29: Memory Management

    UM1743 Kernel description Figure 24. Setting the time and the date Figure 25. Setting the time and the date for STM32446E-EVAL demonstration Note: The clock and the date are not shown in STM32F479I-EVAL and STM32F469I-DISCO demonstrations. 3.12 Memory management A huge amount of system RAM is allocated to the GUI internal heap, the kernel memory manager is used as a standalone memory allocator for some specific data blocks, like file lists and kernel log buffer.
  • Page 30: Figure 26. Memory Heap For Stm32Cubef4 Demonstration

    For the STM32CubeF4 demonstration, the memory heap is located in the CCM data RAM. Figure 26. Memory heap for STM32CubeF4 demonstration The memory manager offers a set of standard high level APIs to allocate and free memory block from the predefined pool.
  • Page 31: Demonstration Repository

    UM1743 Kernel description For STM32446E-EVAL demonstration, the memory heap is located in the external SDRAM memory. Note: For STM32F479I-EVAL, STM32F469I-DISCO and STM32F412G-DISCO demonstrations the memory manager is not applicable. Table 4 shows the different APIs offered by the memory manager module. Table 4.
  • Page 32: Figure 27. Folder Structure

    Kernel description UM1743 Figure 27. Folder structure The demonstration sources are located in the projects folder of the STM32Cube package for each supported board. The sources are divided into five groups described as follows: Core: contains the kernel files Modules: contains the system and user modules including the graphical aspect and the modules functionalities.
  • Page 33: Kernel Components

    UM1743 Kernel description 3.14 Kernel components Table 5. Kernel components list Function Description Kernel core Kernel core and utilities Modules User and system modules STM32 HAL Drivers STM32Cube HAL driver relative to the STM32 device under use BSP Drivers Evaluation board (or discovery kit) BSP drivers ®...
  • Page 34: Hardware Settings

    Kernel description UM1743 3.16 Hardware settings The STM32CubeF4 demonstration supports STM32F4xx devices and runs on the following demonstration boards from STMicroelectronics: • STM324x9I-EVAL • STM324xG-EVAL • STM32F429I-Discovery • STM32446E-EVAL • STM32F479I-EVAL • STM32F469I-DISCO • STM32F412G-DISCO Figure 28. STM32Cube demonstration boards STM32F412G-DISCO Table 7.
  • Page 35 UM1743 Kernel description Table 7. Jumpers for different demonstration boards (continued) Board Jumper Position description JP5/JP6 <2-3> (used for Audio demonstration) <1-2> (used for VNC server demonstration) STM32F479I-EVAL Fitted (Power on MCU) JP17/JP18 <2-3> (used for Audio recorder demonstration) JP11 Fitted (disables the NOR Flash write protection) STM32F469I-DISCO Fitted (Power on MCU)
  • Page 36: How To Create A New Module

    (buttons, check boxes, progress bars…) used to control and monitor the module's functionalities. The STM32CubeF4 demonstration package provides a PC tool; the GUIBuilder (Figure that allows easily and quickly creating the module frame window and all its components in few steps.
  • Page 37: Graphics Customization

    UM1743 How to create a new module Graphics customization After the basic module graphical appearance is created, it is then possible to customize some graphical elements, such as the buttons, by replacing the standard aspect by the user defined image. To do this, a new element drawing callback should be created and used instead of the original one.
  • Page 38: Adding A Module To The Main Desktop

    How to create a new module UM1743 Then, each module has its own Startup function which simply consists of the graphical module creation, initialization and link to the main callback: In the example above cbDialog refers to the main module callback routine. Its general skeleton is structured like the following: The list of windows messages presented in the code portion above (WM_INIT_DIALOG and WM_NOTIFY_PARENT) is not exhaustive, but represents the essential message IDs used:...
  • Page 39: Module's Direct Open

    Figure 31. Direct open from file browser In the STM32CubeF4 demonstration, there are three modules linked to the file browser contextual menu: •...
  • Page 40: Demonstration Customization And Configuration

    Frame buffers locations: The physical location of frame buffer is defined through LCD_LAYERX_FRAME_BUFFER. Figure 32. LCDConf location Layers management In the STM32CubeF4 demonstration package with the STM324x9I-EVAL, Discovery Kit, STM32F479I-EVAL and STM32F469I-DISCO, GUI_NUM_LAYERS is set to 2 (both layers are used): •...
  • Page 41: Touchscreen Calibration

    UM1743 Demonstration customization and configuration Touchscreen calibration When the demonstration is launched for the first time, the touchscreen needs to be calibrated. A full set of dedicated routines is included in the demonstration package and regrouped into k_calibration.c file (Figure 33).
  • Page 42: Bsp Customization

    Demonstration customization and configuration UM1743 Figure 34. Calibration steps Once this runtime calibration is done, the touch screen calibration parameters are saved to the RTC Backup data registers: RTC_BKP_DR0 and RTC_BKP_DR1, so the next time the application is restarted, these parameters are automatically restored and there is no need to re-calibrate the touchscreen.
  • Page 43: Touch Screen Configuration

    UM1743 Demonstration customization and configuration Figure 35. SDRAM initialization The SDRAM external memory must be initialized before the GUI initialization to allow its use as LCD layers frame buffer. Table 8. LCD frame buffer locations Layer Address 0xC0200000 LCD Layer0 0xC0000000 (for STM32F479I-EVAL and STM32F469-DISCO) LCD Layer1 0xC0400000...
  • Page 44: Figure 36. Touch Screen Initialization

    Demonstration customization and configuration UM1743 Figure 36. Touch screen initialization The touch screen is initialized in 'k_BspInit' following the used screen resolution as shown in the code below. 44/111 DocID026161 Rev 4...
  • Page 45: Performance

    In the STM32CubeF4 demonstration, the layer 0 is dedicated for the background while the layer 1 with transparency activated is dedicated for the main desktop, this will allow to the kernel to keep the background unchanged during the desktop visual changes without refreshing the background image.
  • Page 46: Hardware Acceleration

    Performance UM1743 Figure 38. Independent layer management Hardware acceleration With the STM324x9I-EVAL and Discovery Kit demonstration, the hardware acceleration capabilities of the STM32F429/ STM32F439 cores are used. STemWin offers a set of customization callbacks to changes the default behavior based on the hardware capabilities, the optimized processes are implemented in the LCDConf.c file and implement the following features: Color conversion...
  • Page 47 UM1743 Performance Copy buffers Setting up the function for transferring the front- to the back buffer when using multiple buffers: LCD_SetDevFunc(LayerIndex, LCD_DEVFUNC_COPYBUFFER, pFunc); Fading operations Setting up the function for mixing up a background and a foreground buffer used for fading memory devices: GUI_SetFuncMixColorsBulk(pFunc);...
  • Page 48: Footprint

    Footprint UM1743 Footprint The purpose of the following sections is to provide the memory requirements for all the demonstration modules, including jpeg decoder and STemWin's main GUI components. The aim is to have an estimation of memory requirement in case of suppression or addition of a module or feature.
  • Page 49: Stemwin Features Resources

    UM1743 Footprint Table 11. Modules footprint (continued) File code [byte] data [byte] const [byte] Camera 2467 62629 File Browser 3062 69083 Game 4188 1916 33432 Image Browser 5308 1956 32862 System 2486 33506 USB Device 195529 Video Player 6476 32646 1.
  • Page 50: Table 13. Memostemwin Components Memory Requirements

    Footprint UM1743 Table 13. MemoSTemWin components memory requirements Component Description Additional memory requirements of basic Kbytes Kbytes Windows Manager application when using the Windows Manager Additional memory requirements of basic Kbytes Kbytes Memory Devices application when using memory devices Additional memory requirements for the Kbytes Antialiasing 2 * LCD_XSIZE...
  • Page 51 UM1743 Footprint Table 14. Widget memory requirements (continued) Component Description MULTIPAGE 3.9 Kbytes 32 bytes PROGBAR 1.3 Kbytes 20 bytes RADIOBUTTON 1.4 Kbytes 32 bytes SCROLLBAR 2.0 Kbytes 14 bytes SLIDER 1.3 Kbytes 16 bytes TEXT 1.0 Kbytes 16 bytes CALENDAR 0.6 Kbytes 32 bytes...
  • Page 52: Demonstration Functional Description (Stm324X9I-Eval, Stm324Xg-Eval, Stm32F429I-Discovery And Stm32446E-Eval)

    39). Figure 39. CPU usage display The system utilities are accessible during the STM32CubeF4 demonstration running time, using the system button (ST Logo) in top left of the main desktop. The system utilities button offers the following services: • CPU usage history •...
  • Page 53: Cpu Usage

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- 8.1.1 CPU usage The CPU usage utility provides a graphical representation of the CPU usage evolution (Figure 40) during the demonstration run time starting for the first time it was launched. Note that once launched the CPU usage utilities keep running in background and can be restored in any time.
  • Page 54: Process Viewer

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- 8.1.3 Process viewer The process viewer (Figure 42) allows users to check and to display the status of the currently running tasks (FreeRTOS) at any time during the demonstration run time. It shows the following information: Current running tasks names.
  • Page 55: Figure 43. Demonstration Global Information

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Figure 43. Demonstration global information Figure 44. Demonstration general settings DocID026161 Rev 4 55/111...
  • Page 56: Table 15. Available Settings

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Table 15 shows the different settings that can be changed. Table 15. Available settings Configuration item Description Checking this box allows the sprites to move on the background desktop Enable sprites Enable background mode Not used (reserved for future use) Allow to run the demonstration at maximum speed.
  • Page 57: File Browser

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- 8.2.2 File browser Overview The File browser module is a system module that allows to explore the connected storage unit(s), to delete or to open a selected file. The file list structure is built during the media connection and updated after a connection status change of one of the used media.
  • Page 58: Figure 47. File Browser Module Architecture

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Figure 47. File browser module architecture To open the contextual file menu, user has to select a file (selecting a folder has no effect). The following actions are accessible through the contextual menu: Open file: if a file extension is linked to the direct open file feature of the kernel, the associated application with this extension is launched and the file is opened automatically (Figure...
  • Page 59: Game

    8.2.3 Game The game coming in the STM32CubeF4 demonstration is based on the Reversi game. It is a strategy board game for two players, played on an 8×8 board. The goal of the game is to have the majority of disks turned to display your color when the last playable empty square is filled.
  • Page 60: Benchmark

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- 8.2.4 Benchmark Overview The Benchmark module is a system module that allows measure the graphical performance by measuring the time needed to draw several colored rectangles in random position with random size during a specific period. The result is given in pixel per second. Functional description The benchmark starts immediately once the start speed benchmark button is pressed.
  • Page 61: Table 16. Data Structure For Audio

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Figure 52. Audio player module architecture Data structure used Table 16 contains the different data structure used in audio player module and a brief description of each of them. Table 16. Data structure for audio Structure Description WAV_InfoTypedef...
  • Page 62: Figure 53. Audio Player Module Startup

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Table 16. Data structure for audio (continued) Structure Description Contains the different possible error. – AUDIOPLAYER_ERROR_NONE – AUDIOPLAYER_ERROR_IO AUDIOPLAYER_ErrorTypdef – AUDIOPLAYER_ERROR_HW – AUDIOPLAYER_ERROR_MEM – AUDIOPLAYER_ERROR_FORMAT_NOTSUPPORTED Contains the different Buffer state – BUFFER_OFFSET_NONE BUFFER_StateTypeDef – BUFFER_OFFSET_HALF –...
  • Page 63: Table 17. Audio Module Controls

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Table 17. Audio module controls Button Preview Description Changes the audio player state to “AUDIOPLAYER_PLAY” Reads the wave file from storage unit Sets the frequency Play button Starts or resumes the audio task Starts playing audio stream from a data buffer using “BSP_AUDIO_OUT_Play”...
  • Page 64: Video

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- 8.2.6 Video Overview The video player module provides a video solution based on the STM32F4xx and STemWin movie API. It supports playing movie in emf format. Architecture Figure 54 shows the different video player modules and their connections and interactions with the external components.
  • Page 65: Table 18. Video Module Controls

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- When the video player is started, the following actions are executed: • The graphical components are initialized: – The video frame – The control buttons – The list box field • Memory is allocated to save the video list (pVideoList) and the file information (pFileInfo).
  • Page 66 Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Table 18. Video module controls (continued) Button Preview Description Points to the next video file Next button Stops video playing Starts playing the next video file if play button is pressed Opens file browser window and choose emf file from Add file to playlist available storage unit to be added to playlist Opens file browser window and choose entire folder from...
  • Page 67: Figure 56. Emf Generation Environment

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Figure 56. EMF generation environment Create an emf file from JPEG file using JPEG2Movie tool available in STemWin package (see Figure 57). Figure 57. JPEG2Movie overview DocID026161 Rev 4 67/111...
  • Page 68: Table 19. Batch Files Description

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- The above steps could be done once using a predefined batch (included in the STemWin package) as shown in Figure Figure 58. EMF file generation For more information about how to use the emf generation batches, refer to the STemWin User and Reference Guide (UM3001).
  • Page 69: Table 20. Variables Description

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Prep.bat The Prep.bat is required to prepare the environment for the actual process. Calling it directly will not have any effect. It is called by the MakeMovie.bat. To be able to use the batch files it is required to adapt this file at first.
  • Page 70: Usb Mass Storage Device (Usbd)

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Since the FFmpeg output can differ strongly from the output of previous actions, the MakeMovie.bat deletes all output files in the first place. The output folder is defined by in the environmental variable %OUTPUT% in Prep.bat. After that it uses FFmpeg.exe to create the required JPEG files for each frame.
  • Page 71: Table 22. Data Structure For Usbd Module

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Data structure used Table 22. Data structure for USBD module Structure Description USBDSettingsTypeDef sd_mounted: connection status Functional description Run USB Device demonstration by clicking USB device icon in the main desktop, as in Figure Figure 60.
  • Page 72: Camera

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Table 23. USBD module controls (continued) Button Preview Description Changes the microSD logo as follows: Insert microSD card Changes the microSD logo as follows: Remove microSD card Close Closes USBD module 8.2.8 Camera Overview The camera application allows to directly and permanently display on the LCD the image captured using the camera module.
  • Page 73: Figure 61. Camera Module Architecture

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Figure 61. Camera module architecture Functional description To start the camera module click on the Camera icon, as indicated in Figure Figure 62. Camera module startup When the camera module is started, the following actions are executed: •...
  • Page 74: Image Viewer

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Table 24. Camera module controls Button Preview Description Settings Creates and shows the settings dialog Checks the camera state Displays a popup message ("Saving image...") Capture Saves the current image to the specified file (default path is the root) Deletes the popup message Frees allocated memory during the initialization Close...
  • Page 75: Figure 63. Image Viewer Architecture

    UM1743Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I- Figure 63. Image viewer architecture Functional description There are two ways to start Image viewer module: • Either by touching the Image viewer icon (Figure 64); • Or by using the file browser contextual menu: direct open feature. When the image viewer is started, the following actions are executed: •...
  • Page 76: Table 25. Image Viewer Module Controls

    Demonstration functional description (STM324x9I-EVAL, STM324xG-EVAL, STM32F429I-Discov- Figure 64. Image viewer startup Table 25 summarizes the different actions behind each control button. Table 25. Image viewer module controls Button Preview Description Frees allocated memory Close Ends the module dialog Closes the current image Opens the previous image Previous Refreshes the image frame...
  • Page 77: Demonstration Functional Description (Stm32F479I-Eval And Stm32F469I-Disco)

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Modules 9.1.1 Audio Overview The audio player module provides a complete audio solution based on the STM32F4xx and delivers a high-quality music experience. It supports playing music in WAV format but may be extended to support other compressed formats such as MP3 and WMA audio formats.
  • Page 78: Figure 66. Audio Player Module Performance Mechanisms

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Figure 66. Audio player module performance mechanisms Functional description The audio player initialization is carried out in the startup step: all the audio player states, the speaker and the volume value are initialized (when the Play button in the audio player interface is pressed to start the process): •...
  • Page 79: Figure 68. Adding Audio Files To The Playlist

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 68. Adding audio files to the playlist Figure 69. Equalizer and loudness frame Figure 70. Background mode DocID026161 Rev 4 79/111...
  • Page 80: Table 26. Image Viewer Module Controls

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Figure 71. Hardware connectivity Table 26. Image viewer module controls Button Preview Description Changes the audio player state to “AUDIOPLAYER_PLAY” Reads the wave file from storage unit Sets the frequency Play Starts or resumes the audio task Starts playing audio stream from a data buffer using “BSP_AUDIO_OUT_Play”...
  • Page 81: Video

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Table 26. Image viewer module controls (continued) Button Preview Description Point to the next wave file Next Stops audio playing Starts playing the next wave file if play button is pressed Add file to Open file browser window and choose wave file to be added to playlist playlist Open file browser window and choose entire folder to be added to...
  • Page 82: Figure 72. Video Player Module Architecture

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Features • Video Format: STemWin emf Video Format (Motion-Jpeg) • Performance: MCU Load < 70% / Rate: up to 15 fps • Video files stored in USB Disk flash (USB High Speed) • Use of the 2 LCD layers (Playback control/ Video display) •...
  • Page 83: Figure 73. Video Player Module Performance

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 73. Video player module performance Functional description • Start Video player module by touching the video player icon • When the video player is started, the icon shown in Figure 74 is displayed •...
  • Page 84: Figure 75. Adding Files To The Playlist

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Figure 75. Adding files to the playlist Figure 76. Warning popup Figure 77. Video is playing 84/111 DocID026161 Rev 4...
  • Page 85: Table 27. Video Module Controls

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 78. Hiding control keys and other information Table 27. Video module controls Button Preview Description Checks if the video size is not supported Supported video size: 0 < xSize < 1024 and 0 < ySize < 768 Play Changes the video player state to “VIDEO_PLAY”...
  • Page 86: Figure 79. Emf Generation Format

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Video file creation (emf) To be able to play movies with the STemWin API functions it is required to create files of the STemWin specific EmWin movie file format. There are two steps to generate an emf file: Convert files of any MPEG file format into a folder of single JPEG files for each frame (see Figure...
  • Page 87: Table 28. Batch File Description

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 81. EMF file generation Table 28. Batch file description File Description Sets some defaults to be used. Needs to be adapted as explained in Prep.bat Prep.bat. MakeMovie.bat Main conversion file. Not to be adapted normally. Some helper files for different resolutions.
  • Page 88: Table 29. Variable Description

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Table 29. Variable description Variable Description Destination folder for the JPEG files. Will be cleared automatically %OUTPUT% when starting the conversion with MakeMovie.bat. Access variable for the FFmpeg tool. Should contain the complete %FFMPEG% path required to call FFmpeg.exe.
  • Page 89: Audio Recorder

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) simply drag and drop the file to be converted to one of these helper files. After that an .emf file with the corresponding size-postfix can be found in the source file folder. 9.1.3 Audio recorder Overview The audio recorder module can be used to record audio frames in WAV format, save them in...
  • Page 90: Figure 83. Audio Recorder Module Startup

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Functional description • Start audio recorder module by touching the audio recorder icon as shown in Figure 83 • Press on the Record icon to start recording (see Figure • Click on Stop icon to save the recorded data in USB disk or Click cancel to discard them (Figure •...
  • Page 91: Table 31. Audio Module Controls

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 86. Play the recorded wave file Figure 87. Hardware connectivity Table 31. Audio module controls Button Preview Description Reads the recorded wave file from storage unit Play Replaces Discard/start button by play button Suspends the audio task Pause Pauses the audio file record...
  • Page 92: Vnc Server

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Table 31. Audio module controls (continued) Button Preview Description Save the recorded file in storage unit Stop Suspends the audio task Stops audio recording Start Starts audio recording Stops audio recoding Cancel Discard the recorded wave Menu Closes Audio recording module 9.1.4...
  • Page 93: Figure 88. Video Player Module Architecture

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 88. Video player module architecture Functional description • Click on the VNC Server icon (Figure • Enable or disable secure mode (Figure • Start the VNC server (Figure • Check that VNC Connection is established and IP Address assigned (Figure •...
  • Page 94: Figure 90. Enable / Disable Secure Mode

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Figure 90. Enable / Disable secure mode Figure 91. Start VNC server Figure 92. IP address assigned 94/111 DocID026161 Rev 4...
  • Page 95: Figure 93. Run Vnc Client

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) Figure 93. Run VNC Client Figure 94. Background mode DocID026161 Rev 4 95/111...
  • Page 96: Table 32. Vnc Server Module Controls

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Hardware connectivity Figure 95. Hardware connectivity Table 32. VNC server module controls Button Preview Description Background Activates background and any other module can be started Stop Stops the VNC server Play Starts the VNC server Secure Enables or disables secure mode Menu...
  • Page 97: Game

    UM1743 Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) 9.1.5 Game Overview Similarly to what seen in Section 8.2.3, the game for this demonstration is based on the Reversi game, the microcontroller being one of the two players (Figure 96). Figure 96. Reversi game The GUI will ask the user to start a new game when the ongoing one is over.
  • Page 98: System Information

    Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) UM1743 Figure 98. Home alarm Choose a room and click on “watch room” to show a static picture simulated as home camera, as indicated in Figure Figure 99. Watching a room Note: Static pictures are used instead of camera streaming. 9.1.8 System information Overview...
  • Page 99: Demonstration Functional Description

    UM1743 Demonstration functional description (STM32F412GDISCO) Demonstration functional description (STM32F412GDISCO) 10.1 Modules 10.1.1 Audio player Overview The audio player module provides a complete audio solution based on the STM32Fxxx and delivers a high-quality music experience. It supports playing music in WAV format but may be extended to support other compressed formats, such as MP3 and WMA.
  • Page 100: Table 33. Audio Player Module Controls

    Demonstration functional description (STM32F412GDISCO) UM1743 Process description The audio player initialization is done in the startup step. In this step all the audio player states, the speaker and the volume value are initialized, and only when the play button in the audio player interface is pressed the process can be started.
  • Page 101 UM1743 Demonstration functional description (STM32F412GDISCO) Table 33. Audio player module controls (continued) Button Preview Description Volume Decreases the volume down Exit Closes the module DocID026161 Rev 4 101/111...
  • Page 102: Audio Recorder

    Demonstration functional description (STM32F412GDISCO) UM1743 10.1.2 Audio recorder Overview The audio recorder module can be used to record audio frames in WAV format, save them in the storage unit, and play them later. Features • Audio Format: WAV format without compression with 16 k sampling stereo •...
  • Page 103: Table 34. Audio Recorder Module Controls

    UM1743 Demonstration functional description (STM32F412GDISCO) Functional description Start audio recorder module by touching the audio recorder icon, as indicated in Figure 104. Figure 104. Audio recorder module startup Table 34. Audio recorder module controls Button Preview Description Starts recording audio Record Replaces record button by pause button Play...
  • Page 104: Video Module

    Demonstration functional description (STM32F412GDISCO) UM1743 10.1.3 Video module Overview The video player module provides a video solution based on the STM32F4xxx and the STemWin movie APIs. It supports the AVI format. Features • Video Format: AVI • Performance: frame rate up to 13 fps •...
  • Page 105: Figure 106. Video Recorder Module Startup

    UM1743 Demonstration functional description (STM32F412GDISCO) Functional description Start video recorder module by touching the audio recorder icon, as indicated in Figure 106. When the video player is started, the first AVI file stored in the storage unit starts playing. Figure 106. Video recorder module startup DocID026161 Rev 4 105/111...
  • Page 106: Analog Clock Module

    Demonstration functional description (STM32F412GDISCO) UM1743 10.1.4 Analog clock module Overview The analog clock module enables to show and adjust the analog time by changing the RTC configuration. Functional description Start analog clock module by touching the analog clock icon (Figure 107).
  • Page 107: Usb Devices Module

    UM1743 Demonstration functional description (STM32F412GDISCO) 10.1.5 USB devices module Overview The USB device (USBD) module includes mass storage device application using the Micro SD memory. Architecture Figure 109 shows the different video player modules, and their connections and interactions with the external components. Figure 109.
  • Page 108: System Information

    Demonstration functional description (STM32F412GDISCO) UM1743 Figure 111. Connection of an USB device 10.1.6 System information Overview The system information module shows key information, such as used board, part number, the current CPU clock and demonstration revision. Functional description The system information module is activated by touching the dedicated icon, as indicated in Figure 112.
  • Page 109: Revision History

    – Figure 19: Starting file execution for STM32446E-EVAL demonstration; – Figure 23: Detection of storage units for STM32446E-EVAL demonstration; – Figure 26: Memory heap for STM32CubeF4 demonstration; – footnote Section 4.5: Module's direct open; – note in Section 6: Performance.
  • Page 110: Figure 8. Main Desktop Window For Stm32479I-Eval Demonstration

    Table 35. Document revision history (continued) Date Revision Changes Introduced STM32F479I-EVAL and STM32F469I-DISCO boards. Added: – Section 3.5: ST widget add-ons and its subsections; – Section 9: Demonstration functional description (STM32F479I-EVAL and STM32F469I-DISCO) and its subsections; – Figure 8: Main desktop window for STM32479I-EVAL demonstration;...
  • Page 111 ST products and/or to this document at any time without notice. Purchasers should obtain the latest relevant information on ST products before placing orders. ST products are sold pursuant to ST’s terms and conditions of sale in place at the time of order acknowledgement.

Table of Contents