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