Wakeup Light with touch user interface, anti-aliased Font, SD card access and RTC usage on STM32F746NG-DISCO board

Dependencies:   BSP_DISCO_F746NG_patch_fixed LCD_DISCO_F746NG TS_DISCO_F746NG FATFileSystem TinyJpgDec_interwork mbed-src

Embed: (wiki syntax)

« Back to documentation index

TM_HAL

Main description and usage of TM HAL based libraries. More...

Modules

 TM_HAL_Family
 

In stm32fxxx_hal.h file you have to specify STM32 family used for HAL drivers.



Detailed Description

Main description and usage of TM HAL based libraries.

About libraries

These libraries are provided by Tilen Majerle and are developed under GNU GPL v3 licence. For more information about that, please check website of license.

To use it, I suppose you know C language and at least basics of STM32 devices (especially STM32F0, STM32F4 or STM32F7 series).

Download libraries

Download for all libraries is on this link: http://stm32f4-discovery.com/?wpdmdl=2618

Examples

Each library has Keil uVision based example on my Github account, https://github.com/MaJerle/stm32fxxx_hal_libraries.

If you are beginner, then I suggest you to download entire repository from Github, install basic demo version of Keil uVision and open examples directly from download. Almost all examples works with demo version of Keil uVision.

Libraries structure

Each library is structured in the same way where you have these parts:

  • Header file:
    • Library description with link on website
    • Includes section
    • Defines section for different configurations in library
    • Enumerations and structures section
    • Function declaration section
  • Source file:
    • Function implementations

Each library includes at least these 2 files:

  • stm32fxxx_hal.h file: This file was done by me for better organization between several STM32 families to use with my libraries for future use. It sets some basic defines, which can also be set using compiler's preprocessor defines. Check file for more information with detailed description.
  • defines.h file: This file is totally based on user and should also be created by user.

It is used for library configuration settings, so you don't have to edit library file. If you edit library file, then if new version is out, it will be overwritten what you don't wanna have.

Check example below for meaning.

//------------------------------------
//tm_stm32_exti.h file:
//------------------------------------
//Content in this file is similar to this below:

//Include defines.h file for user configuration
#include "defines.h"

//Set default NVIC preemption priority if not defined by user to 0x03
#ifndef EXTI_NVIC_PRIORITY
#define EXTI_NVIC_PRIORITY     0x03
#endif

//------------------------------------
//defines.h file: (set by user)
//------------------------------------

//User wants to change that, use defines.h file like this:
#ifndef DEFINES_FILE
#define DEFINES_FILE

//Let's set EXTI NVIC preemption priority to highest, so we will do:
#define EXTI_NVIC_PRIORITY    0x00

#endif

Code above shows how you can use defines.h file to change default library settings.

HAL Source from ST

TM HAL libraries works on STM32Cube provided from ST and are not included in package of libraries.

Note:
You have to go to ST website and download STM32Cube package for your family and use that STM32Fxxx_HAL_Drivers libraries in your project together with my libraries. On my Github, you have example how they are used together.
About defines.h file

Please check above about this.