nordic

Fork of nRF51822 by Nordic Semiconductor

Committer:
vcoubard
Date:
Mon Jan 11 10:19:10 2016 +0000
Revision:
553:20b282c26f96
Parent:
542:884f95bf5351
Child:
554:2a413611e569
Synchronized with git rev f4f35c8a
Author: Rohit Grover
Release 2.1.1
=============

A minor release to separate the concept of minlen and len in
GattCharacteristic.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
vcoubard 542:884f95bf5351 1 /* mbed Microcontroller Library
vcoubard 542:884f95bf5351 2 * Copyright (c) 2006-2013 ARM Limited
vcoubard 542:884f95bf5351 3 *
vcoubard 542:884f95bf5351 4 * Licensed under the Apache License, Version 2.0 (the "License");
vcoubard 542:884f95bf5351 5 * you may not use this file except in compliance with the License.
vcoubard 542:884f95bf5351 6 * You may obtain a copy of the License at
vcoubard 542:884f95bf5351 7 *
vcoubard 542:884f95bf5351 8 * http://www.apache.org/licenses/LICENSE-2.0
vcoubard 542:884f95bf5351 9 *
vcoubard 542:884f95bf5351 10 * Unless required by applicable law or agreed to in writing, software
vcoubard 542:884f95bf5351 11 * distributed under the License is distributed on an "AS IS" BASIS,
vcoubard 542:884f95bf5351 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
vcoubard 542:884f95bf5351 13 * See the License for the specific language governing permissions and
vcoubard 542:884f95bf5351 14 * limitations under the License.
vcoubard 542:884f95bf5351 15 */
vcoubard 542:884f95bf5351 16
vcoubard 542:884f95bf5351 17 #ifndef _CUSTOM_HELPER_H_
vcoubard 542:884f95bf5351 18 #define _CUSTOM_HELPER_H_
vcoubard 542:884f95bf5351 19
vcoubard 542:884f95bf5351 20 #include "common/common.h"
vcoubard 542:884f95bf5351 21 #include "ble.h"
vcoubard 542:884f95bf5351 22 #include "ble/UUID.h"
vcoubard 542:884f95bf5351 23 #include "ble/GattCharacteristic.h"
vcoubard 542:884f95bf5351 24
vcoubard 542:884f95bf5351 25 #ifdef __cplusplus
vcoubard 542:884f95bf5351 26 extern "C" {
vcoubard 542:884f95bf5351 27 #endif
vcoubard 542:884f95bf5351 28
vcoubard 542:884f95bf5351 29 uint8_t custom_add_uuid_base(uint8_t const *const p_uuid_base);
vcoubard 542:884f95bf5351 30 error_t custom_decode_uuid(uint8_t const *const p_uuid_base,
vcoubard 542:884f95bf5351 31 ble_uuid_t *p_uuid);
vcoubard 542:884f95bf5351 32 ble_uuid_t custom_convert_to_nordic_uuid(const UUID &uuid);
vcoubard 542:884f95bf5351 33
vcoubard 542:884f95bf5351 34 error_t custom_add_in_characteristic(uint16_t service_handle,
vcoubard 542:884f95bf5351 35 ble_uuid_t *p_uuid,
vcoubard 542:884f95bf5351 36 uint8_t properties,
vcoubard 542:884f95bf5351 37 SecurityManager::SecurityMode_t requiredSecurity,
vcoubard 542:884f95bf5351 38 uint8_t *p_data,
vcoubard 553:20b282c26f96 39 uint16_t length,
vcoubard 542:884f95bf5351 40 uint16_t max_length,
vcoubard 542:884f95bf5351 41 const uint8_t *userDescriptionDescriptorValuePtr,
vcoubard 542:884f95bf5351 42 uint16_t userDescriptionDescriptorValueLen,
vcoubard 542:884f95bf5351 43 bool readAuthorization,
vcoubard 542:884f95bf5351 44 bool writeAuthorization,
vcoubard 542:884f95bf5351 45 ble_gatts_char_handles_t *p_char_handle);
vcoubard 542:884f95bf5351 46
vcoubard 542:884f95bf5351 47 error_t custom_add_in_descriptor(uint16_t char_handle,
vcoubard 542:884f95bf5351 48 ble_uuid_t *p_uuid,
vcoubard 542:884f95bf5351 49 uint8_t *p_data,
vcoubard 553:20b282c26f96 50 uint16_t length,
vcoubard 542:884f95bf5351 51 uint16_t max_length,
vcoubard 542:884f95bf5351 52 uint16_t *p_desc_handle);
vcoubard 542:884f95bf5351 53
vcoubard 542:884f95bf5351 54 #ifdef __cplusplus
vcoubard 542:884f95bf5351 55 }
vcoubard 542:884f95bf5351 56 #endif
vcoubard 542:884f95bf5351 57
rgrover1 82:6c51cbe4bc12 58 #endif // ifndef _CUSTOM_HELPER_H_