ver:init

Committer:
iv123
Date:
Sun Jun 18 16:11:03 2017 +0000
Revision:
0:4946262d6030
Initial commit

Who changed what in which revision?

UserRevisionLine numberNew contents of line
iv123 0:4946262d6030 1 /* mbed Microcontroller Library
iv123 0:4946262d6030 2 * Copyright (c) 2006-2013 ARM Limited
iv123 0:4946262d6030 3 *
iv123 0:4946262d6030 4 * Licensed under the Apache License, Version 2.0 (the "License");
iv123 0:4946262d6030 5 * you may not use this file except in compliance with the License.
iv123 0:4946262d6030 6 * You may obtain a copy of the License at
iv123 0:4946262d6030 7 *
iv123 0:4946262d6030 8 * http://www.apache.org/licenses/LICENSE-2.0
iv123 0:4946262d6030 9 *
iv123 0:4946262d6030 10 * Unless required by applicable law or agreed to in writing, software
iv123 0:4946262d6030 11 * distributed under the License is distributed on an "AS IS" BASIS,
iv123 0:4946262d6030 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
iv123 0:4946262d6030 13 * See the License for the specific language governing permissions and
iv123 0:4946262d6030 14 * limitations under the License.
iv123 0:4946262d6030 15 */
iv123 0:4946262d6030 16
iv123 0:4946262d6030 17
iv123 0:4946262d6030 18 #ifndef _BTLE_H_
iv123 0:4946262d6030 19 #define _BTLE_H_
iv123 0:4946262d6030 20
iv123 0:4946262d6030 21
iv123 0:4946262d6030 22 #ifdef __cplusplus
iv123 0:4946262d6030 23 extern "C" {
iv123 0:4946262d6030 24 #endif
iv123 0:4946262d6030 25
iv123 0:4946262d6030 26 #include <stdio.h>
iv123 0:4946262d6030 27 #include <string.h>
iv123 0:4946262d6030 28
iv123 0:4946262d6030 29 #include "ble_hci.h"
iv123 0:4946262d6030 30 #include "bluenrg_aci.h"
iv123 0:4946262d6030 31 #include "ble_hci_const.h"
iv123 0:4946262d6030 32 #include "bluenrg_hal_aci.h"
iv123 0:4946262d6030 33 #include "stm32_bluenrg_ble.h"
iv123 0:4946262d6030 34 #include "bluenrg_gap.h"
iv123 0:4946262d6030 35 #include "bluenrg_gatt_server.h"
iv123 0:4946262d6030 36
iv123 0:4946262d6030 37 extern uint16_t g_gap_service_handle;
iv123 0:4946262d6030 38 extern uint16_t g_appearance_char_handle;
iv123 0:4946262d6030 39 extern uint16_t g_device_name_char_handle;
iv123 0:4946262d6030 40 extern uint16_t g_preferred_connection_parameters_char_handle;
iv123 0:4946262d6030 41
iv123 0:4946262d6030 42 void btleInit(void);
iv123 0:4946262d6030 43 void SPI_Poll(void);
iv123 0:4946262d6030 44 void User_Process(void);
iv123 0:4946262d6030 45 void setConnectable(void);
iv123 0:4946262d6030 46 void setVersionString(uint8_t hwVersion, uint16_t fwVersion);
iv123 0:4946262d6030 47 const char* getVersionString(void);
iv123 0:4946262d6030 48 tBleStatus btleStartRadioScan(uint8_t scan_type,
iv123 0:4946262d6030 49 uint16_t scan_interval,
iv123 0:4946262d6030 50 uint16_t scan_window,
iv123 0:4946262d6030 51 uint8_t own_address_type);
iv123 0:4946262d6030 52
iv123 0:4946262d6030 53
iv123 0:4946262d6030 54 extern int btle_handler_pending;
iv123 0:4946262d6030 55 extern void btle_handler(void);
iv123 0:4946262d6030 56
iv123 0:4946262d6030 57 #ifdef __cplusplus
iv123 0:4946262d6030 58 }
iv123 0:4946262d6030 59 #endif
iv123 0:4946262d6030 60
iv123 0:4946262d6030 61 #endif