First programBLE
Fork of Nucleo_BLE_API by
public/GattCharacteristicWriteCBParams.h@1:79e5c08cbcc7, 2014-12-19 (annotated)
- Committer:
- sjallouli
- Date:
- Fri Dec 19 19:52:49 2014 +0000
- Revision:
- 1:79e5c08cbcc7
- Parent:
- 0:289fd2dae405
change the USARTService->write() method access permission to public
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
sjallouli | 0:289fd2dae405 | 1 | /* mbed Microcontroller Library |
sjallouli | 0:289fd2dae405 | 2 | * Copyright (c) 2006-2013 ARM Limited |
sjallouli | 0:289fd2dae405 | 3 | * |
sjallouli | 0:289fd2dae405 | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
sjallouli | 0:289fd2dae405 | 5 | * you may not use this file except in compliance with the License. |
sjallouli | 0:289fd2dae405 | 6 | * You may obtain a copy of the License at |
sjallouli | 0:289fd2dae405 | 7 | * |
sjallouli | 0:289fd2dae405 | 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
sjallouli | 0:289fd2dae405 | 9 | * |
sjallouli | 0:289fd2dae405 | 10 | * Unless required by applicable law or agreed to in writing, software |
sjallouli | 0:289fd2dae405 | 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
sjallouli | 0:289fd2dae405 | 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
sjallouli | 0:289fd2dae405 | 13 | * See the License for the specific language governing permissions and |
sjallouli | 0:289fd2dae405 | 14 | * limitations under the License. |
sjallouli | 0:289fd2dae405 | 15 | */ |
sjallouli | 0:289fd2dae405 | 16 | |
sjallouli | 0:289fd2dae405 | 17 | #ifndef __GATT_CHARACTERISTIC_WRITE_CB_PARAMS_H__ |
sjallouli | 0:289fd2dae405 | 18 | #define __GATT_CHARACTERISTIC_WRITE_CB_PARAMS_H__ |
sjallouli | 0:289fd2dae405 | 19 | |
sjallouli | 0:289fd2dae405 | 20 | struct GattCharacteristicWriteCBParams { |
sjallouli | 0:289fd2dae405 | 21 | GattAttribute::Handle_t charHandle; |
sjallouli | 0:289fd2dae405 | 22 | enum Type { |
sjallouli | 0:289fd2dae405 | 23 | GATTS_CHAR_OP_INVALID = 0x00, /**< Invalid Operation. */ |
sjallouli | 0:289fd2dae405 | 24 | GATTS_CHAR_OP_WRITE_REQ = 0x01, /**< Write Request. */ |
sjallouli | 0:289fd2dae405 | 25 | GATTS_CHAR_OP_WRITE_CMD = 0x02, /**< Write Command. */ |
sjallouli | 0:289fd2dae405 | 26 | GATTS_CHAR_OP_SIGN_WRITE_CMD = 0x03, /**< Signed Write Command. */ |
sjallouli | 0:289fd2dae405 | 27 | GATTS_CHAR_OP_PREP_WRITE_REQ = 0x04, /**< Prepare Write Request. */ |
sjallouli | 0:289fd2dae405 | 28 | GATTS_CHAR_OP_EXEC_WRITE_REQ_CANCEL = 0x05, /**< Execute Write Request: Cancel all prepared writes. */ |
sjallouli | 0:289fd2dae405 | 29 | GATTS_CHAR_OP_EXEC_WRITE_REQ_NOW = 0x06, /**< Execute Write Request: Immediately execute all prepared writes. */ |
sjallouli | 0:289fd2dae405 | 30 | } op; /**< Type of write operation, */ |
sjallouli | 0:289fd2dae405 | 31 | uint16_t offset; /**< Offset for the write operation. */ |
sjallouli | 0:289fd2dae405 | 32 | uint16_t len; /**< Length of the incoming data. */ |
sjallouli | 0:289fd2dae405 | 33 | const uint8_t *data; /**< Incoming data, variable length. */ |
sjallouli | 0:289fd2dae405 | 34 | }; |
sjallouli | 0:289fd2dae405 | 35 | |
sjallouli | 0:289fd2dae405 | 36 | #endif /*__GATT_CHARACTERISTIC_WRITE_CB_PARAMS_H__*/ |