HW layer for the Nucleo board, it only work with old BLE_API

Dependents:   Hello_BLE F446RE-BLE

Fork of X_NUCLEO_IDB0XA1 by ST

Committer:
mridup
Date:
Wed Oct 01 09:52:26 2014 +0000
Revision:
56:20e83a284019
Foundation for mbed HAL adaptation from STM32 Cube HAL adaptation. Tested on L0 initially.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
mridup 56:20e83a284019 1 /******************** (C) COPYRIGHT 2012 STMicroelectronics ********************
mridup 56:20e83a284019 2 * File Name : clock.h
mridup 56:20e83a284019 3 * Author : AMS - HEA&RF BU
mridup 56:20e83a284019 4 * Version : V1.0.0
mridup 56:20e83a284019 5 * Date : 19-July-2012
mridup 56:20e83a284019 6 * Description : Header file for clock library, that gives a simple time
mridup 56:20e83a284019 7 * reference to the BLE Stack.
mridup 56:20e83a284019 8 ********************************************************************************
mridup 56:20e83a284019 9 * THE PRESENT FIRMWARE WHICH IS FOR GUIDANCE ONLY AIMS AT PROVIDING CUSTOMERS
mridup 56:20e83a284019 10 * WITH CODING INFORMATION REGARDING THEIR PRODUCTS IN ORDER FOR THEM TO SAVE TIME.
mridup 56:20e83a284019 11 * AS A RESULT, STMICROELECTRONICS SHALL NOT BE HELD LIABLE FOR ANY DIRECT,
mridup 56:20e83a284019 12 * INDIRECT OR CONSEQUENTIAL DAMAGES WITH RESPECT TO ANY CLAIMS ARISING FROM THE
mridup 56:20e83a284019 13 * CONTENT OF SUCH FIRMWARE AND/OR THE USE MADE BY CUSTOMERS OF THE CODING
mridup 56:20e83a284019 14 * INFORMATION CONTAINED HEREIN IN CONNECTION WITH THEIR PRODUCTS.
mridup 56:20e83a284019 15 *******************************************************************************/
mridup 56:20e83a284019 16
mridup 56:20e83a284019 17 #ifndef __CLOCK_H__
mridup 56:20e83a284019 18 #define __CLOCK_H__
mridup 56:20e83a284019 19
mridup 56:20e83a284019 20 //#include <hal_types.h>
mridup 56:20e83a284019 21 #include <stdint.h>
mridup 56:20e83a284019 22
mridup 56:20e83a284019 23 /**
mridup 56:20e83a284019 24 * Number of clocks in one seconds.
mridup 56:20e83a284019 25 * This value must be set by each platorm implementation, basing on its needs.
mridup 56:20e83a284019 26 */
mridup 56:20e83a284019 27 extern const uint32_t CLOCK_SECOND;
mridup 56:20e83a284019 28
mridup 56:20e83a284019 29 typedef uint32_t tClockTime;
mridup 56:20e83a284019 30
mridup 56:20e83a284019 31 /**
mridup 56:20e83a284019 32 * This function initializes the clock library and should be called before
mridup 56:20e83a284019 33 * any other Stack functions.
mridup 56:20e83a284019 34 *
mridup 56:20e83a284019 35 */
mridup 56:20e83a284019 36 void Clock_Init(void);
mridup 56:20e83a284019 37
mridup 56:20e83a284019 38 /**
mridup 56:20e83a284019 39 * This function returns the current system clock time. it is used by
mridup 56:20e83a284019 40 * the host stack and has to be implemented.
mridup 56:20e83a284019 41 *
mridup 56:20e83a284019 42 * @return The current clock time, measured in system ticks.
mridup 56:20e83a284019 43 */
mridup 56:20e83a284019 44 tClockTime Clock_Time(void);
mridup 56:20e83a284019 45
mridup 56:20e83a284019 46 /**
mridup 56:20e83a284019 47 * This function waits for a given number of milliseconds.
mridup 56:20e83a284019 48 *
mridup 56:20e83a284019 49 */
mridup 56:20e83a284019 50 void Clock_Wait(int i);
mridup 56:20e83a284019 51
mridup 56:20e83a284019 52
mridup 56:20e83a284019 53 #endif /* __CLOCK_H__ */
mridup 56:20e83a284019 54
mridup 56:20e83a284019 55
mridup 56:20e83a284019 56