Nordic stack and drivers for the mbed BLE API
Dependents: BLE_ANCS_SDAPI BLE_temperature BLE_HeartRate writable_gatt ... more
TARGET_MCU_NRF51822/sdk/source/softdevice/s130/headers/ble_ranges.h@638:c90ae1400bf2, 2016-09-14 (annotated)
- Committer:
- Vincent Coubard
- Date:
- Wed Sep 14 14:39:43 2016 +0100
- Revision:
- 638:c90ae1400bf2
Sync with bdab10dc0f90748b6989c8b577771bb403ca6bd8 from ARMmbed/mbed-os.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
Vincent Coubard |
638:c90ae1400bf2 | 1 | /* |
Vincent Coubard |
638:c90ae1400bf2 | 2 | * Copyright (c) Nordic Semiconductor ASA |
Vincent Coubard |
638:c90ae1400bf2 | 3 | * All rights reserved. |
Vincent Coubard |
638:c90ae1400bf2 | 4 | * |
Vincent Coubard |
638:c90ae1400bf2 | 5 | * Redistribution and use in source and binary forms, with or without modification, |
Vincent Coubard |
638:c90ae1400bf2 | 6 | * are permitted provided that the following conditions are met: |
Vincent Coubard |
638:c90ae1400bf2 | 7 | * |
Vincent Coubard |
638:c90ae1400bf2 | 8 | * 1. Redistributions of source code must retain the above copyright notice, this |
Vincent Coubard |
638:c90ae1400bf2 | 9 | * list of conditions and the following disclaimer. |
Vincent Coubard |
638:c90ae1400bf2 | 10 | * |
Vincent Coubard |
638:c90ae1400bf2 | 11 | * 2. Redistributions in binary form must reproduce the above copyright notice, this |
Vincent Coubard |
638:c90ae1400bf2 | 12 | * list of conditions and the following disclaimer in the documentation and/or |
Vincent Coubard |
638:c90ae1400bf2 | 13 | * other materials provided with the distribution. |
Vincent Coubard |
638:c90ae1400bf2 | 14 | * |
Vincent Coubard |
638:c90ae1400bf2 | 15 | * 3. Neither the name of Nordic Semiconductor ASA nor the names of other |
Vincent Coubard |
638:c90ae1400bf2 | 16 | * contributors to this software may be used to endorse or promote products |
Vincent Coubard |
638:c90ae1400bf2 | 17 | * derived from this software without specific prior written permission. |
Vincent Coubard |
638:c90ae1400bf2 | 18 | * |
Vincent Coubard |
638:c90ae1400bf2 | 19 | * |
Vincent Coubard |
638:c90ae1400bf2 | 20 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND |
Vincent Coubard |
638:c90ae1400bf2 | 21 | * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED |
Vincent Coubard |
638:c90ae1400bf2 | 22 | * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
Vincent Coubard |
638:c90ae1400bf2 | 23 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR |
Vincent Coubard |
638:c90ae1400bf2 | 24 | * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES |
Vincent Coubard |
638:c90ae1400bf2 | 25 | * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; |
Vincent Coubard |
638:c90ae1400bf2 | 26 | * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON |
Vincent Coubard |
638:c90ae1400bf2 | 27 | * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
Vincent Coubard |
638:c90ae1400bf2 | 28 | * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS |
Vincent Coubard |
638:c90ae1400bf2 | 29 | * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
Vincent Coubard |
638:c90ae1400bf2 | 30 | * |
Vincent Coubard |
638:c90ae1400bf2 | 31 | */ |
Vincent Coubard |
638:c90ae1400bf2 | 32 | |
Vincent Coubard |
638:c90ae1400bf2 | 33 | /** |
Vincent Coubard |
638:c90ae1400bf2 | 34 | @addtogroup BLE_COMMON |
Vincent Coubard |
638:c90ae1400bf2 | 35 | @{ |
Vincent Coubard |
638:c90ae1400bf2 | 36 | @defgroup ble_ranges Module specific SVC, event and option number subranges |
Vincent Coubard |
638:c90ae1400bf2 | 37 | @{ |
Vincent Coubard |
638:c90ae1400bf2 | 38 | |
Vincent Coubard |
638:c90ae1400bf2 | 39 | @brief Definition of SVC, event and option number subranges for each API module. |
Vincent Coubard |
638:c90ae1400bf2 | 40 | |
Vincent Coubard |
638:c90ae1400bf2 | 41 | @note |
Vincent Coubard |
638:c90ae1400bf2 | 42 | SVCs, event and option numbers are split into subranges for each API module. |
Vincent Coubard |
638:c90ae1400bf2 | 43 | Each module receives its entire allocated range of SVC calls, whether implemented or not, |
Vincent Coubard |
638:c90ae1400bf2 | 44 | but return BLE_ERROR_NOT_SUPPORTED for unimplemented or undefined calls in its range. |
Vincent Coubard |
638:c90ae1400bf2 | 45 | |
Vincent Coubard |
638:c90ae1400bf2 | 46 | Note that the symbols BLE_<module>_SVC_LAST is the end of the allocated SVC range, |
Vincent Coubard |
638:c90ae1400bf2 | 47 | rather than the last SVC function call actually defined and implemented. |
Vincent Coubard |
638:c90ae1400bf2 | 48 | |
Vincent Coubard |
638:c90ae1400bf2 | 49 | Specific SVC, event and option values are defined in each module's ble_<module>.h file, |
Vincent Coubard |
638:c90ae1400bf2 | 50 | which defines names of each individual SVC code based on the range start value. |
Vincent Coubard |
638:c90ae1400bf2 | 51 | */ |
Vincent Coubard |
638:c90ae1400bf2 | 52 | |
Vincent Coubard |
638:c90ae1400bf2 | 53 | #ifndef BLE_RANGES_H__ |
Vincent Coubard |
638:c90ae1400bf2 | 54 | #define BLE_RANGES_H__ |
Vincent Coubard |
638:c90ae1400bf2 | 55 | |
Vincent Coubard |
638:c90ae1400bf2 | 56 | #define BLE_SVC_BASE 0x60 /**< Common BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 57 | #define BLE_SVC_LAST 0x6B /**< Total: 12. */ |
Vincent Coubard |
638:c90ae1400bf2 | 58 | |
Vincent Coubard |
638:c90ae1400bf2 | 59 | #define BLE_RESERVED_SVC_BASE 0x6C /**< Reserved BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 60 | #define BLE_RESERVED_SVC_LAST 0x6F /**< Total: 4. */ |
Vincent Coubard |
638:c90ae1400bf2 | 61 | |
Vincent Coubard |
638:c90ae1400bf2 | 62 | #define BLE_GAP_SVC_BASE 0x70 /**< GAP BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 63 | #define BLE_GAP_SVC_LAST 0x8F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 64 | |
Vincent Coubard |
638:c90ae1400bf2 | 65 | #define BLE_GATTC_SVC_BASE 0x90 /**< GATTC BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 66 | #define BLE_GATTC_SVC_LAST 0x9F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 67 | |
Vincent Coubard |
638:c90ae1400bf2 | 68 | #define BLE_GATTS_SVC_BASE 0xA0 /**< GATTS BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 69 | #define BLE_GATTS_SVC_LAST 0xAF /**< Total: 16. */ |
Vincent Coubard |
638:c90ae1400bf2 | 70 | |
Vincent Coubard |
638:c90ae1400bf2 | 71 | #define BLE_L2CAP_SVC_BASE 0xB0 /**< L2CAP BLE SVC base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 72 | #define BLE_L2CAP_SVC_LAST 0xBF /**< Total: 16. */ |
Vincent Coubard |
638:c90ae1400bf2 | 73 | |
Vincent Coubard |
638:c90ae1400bf2 | 74 | |
Vincent Coubard |
638:c90ae1400bf2 | 75 | #define BLE_EVT_INVALID 0x00 /**< Invalid BLE Event. */ |
Vincent Coubard |
638:c90ae1400bf2 | 76 | |
Vincent Coubard |
638:c90ae1400bf2 | 77 | #define BLE_EVT_BASE 0x01 /**< Common BLE Event base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 78 | #define BLE_EVT_LAST 0x0F /**< Total: 15. */ |
Vincent Coubard |
638:c90ae1400bf2 | 79 | |
Vincent Coubard |
638:c90ae1400bf2 | 80 | #define BLE_GAP_EVT_BASE 0x10 /**< GAP BLE Event base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 81 | #define BLE_GAP_EVT_LAST 0x2F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 82 | |
Vincent Coubard |
638:c90ae1400bf2 | 83 | #define BLE_GATTC_EVT_BASE 0x30 /**< GATTC BLE Event base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 84 | #define BLE_GATTC_EVT_LAST 0x4F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 85 | |
Vincent Coubard |
638:c90ae1400bf2 | 86 | #define BLE_GATTS_EVT_BASE 0x50 /**< GATTS BLE Event base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 87 | #define BLE_GATTS_EVT_LAST 0x6F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 88 | |
Vincent Coubard |
638:c90ae1400bf2 | 89 | #define BLE_L2CAP_EVT_BASE 0x70 /**< L2CAP BLE Event base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 90 | #define BLE_L2CAP_EVT_LAST 0x8F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 91 | |
Vincent Coubard |
638:c90ae1400bf2 | 92 | |
Vincent Coubard |
638:c90ae1400bf2 | 93 | #define BLE_OPT_INVALID 0x00 /**< Invalid BLE Option. */ |
Vincent Coubard |
638:c90ae1400bf2 | 94 | |
Vincent Coubard |
638:c90ae1400bf2 | 95 | #define BLE_OPT_BASE 0x01 /**< Common BLE Option base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 96 | #define BLE_OPT_LAST 0x1F /**< Total: 31. */ |
Vincent Coubard |
638:c90ae1400bf2 | 97 | |
Vincent Coubard |
638:c90ae1400bf2 | 98 | #define BLE_GAP_OPT_BASE 0x20 /**< GAP BLE Option base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 99 | #define BLE_GAP_OPT_LAST 0x3F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 100 | |
Vincent Coubard |
638:c90ae1400bf2 | 101 | #define BLE_GATTC_OPT_BASE 0x40 /**< GATTC BLE Option base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 102 | #define BLE_GATTC_OPT_LAST 0x5F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 103 | |
Vincent Coubard |
638:c90ae1400bf2 | 104 | #define BLE_GATTS_OPT_BASE 0x60 /**< GATTS BLE Option base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 105 | #define BLE_GATTS_OPT_LAST 0x7F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 106 | |
Vincent Coubard |
638:c90ae1400bf2 | 107 | #define BLE_L2CAP_OPT_BASE 0x80 /**< L2CAP BLE Option base. */ |
Vincent Coubard |
638:c90ae1400bf2 | 108 | #define BLE_L2CAP_OPT_LAST 0x9F /**< Total: 32. */ |
Vincent Coubard |
638:c90ae1400bf2 | 109 | |
Vincent Coubard |
638:c90ae1400bf2 | 110 | #endif /* BLE_RANGES_H__ */ |
Vincent Coubard |
638:c90ae1400bf2 | 111 | |
Vincent Coubard |
638:c90ae1400bf2 | 112 | /** |
Vincent Coubard |
638:c90ae1400bf2 | 113 | @} |
Vincent Coubard |
638:c90ae1400bf2 | 114 | @} |
Vincent Coubard |
638:c90ae1400bf2 | 115 | */ |