1/* 2 * Copyright (c) 2021-2022 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16#ifndef OHOS_HDI_BLUETOOTH_HCI_HCI_INTERNAL_H 17#define OHOS_HDI_BLUETOOTH_HCI_HCI_INTERNAL_H 18 19namespace OHOS { 20namespace HDI { 21namespace Bluetooth { 22namespace Hci { 23enum HciPacketType : uint8_t { 24 HCI_PACKET_TYPE_UNKNOWN = 0, 25 HCI_PACKET_TYPE_COMMAND = 1, 26 HCI_PACKET_TYPE_ACL_DATA = 2, 27 HCI_PACKET_TYPE_SCO_DATA = 3, 28 HCI_PACKET_TYPE_EVENT = 4, 29 HCI_PACKET_TYPE_MAX, 30}; 31 32struct PacketHeader { 33 uint8_t headerSize; 34 uint8_t dataLengthOffset; 35 uint8_t dataLengthSize; 36}; 37 38constexpr uint8_t HCI_EVENT_CODE_COMMAND_COMPLETE = 0x0E; 39constexpr uint8_t HCI_EVENT_CODE_VENDOR_SPECIFIC = 0xFF; 40} // namespace Hci 41} // namespace Bluetooth 42} // namespace HDI 43} // namespace OHOS 44#endif /* OHOS_HDI_BLUETOOTH_HCI_HCI_INTERNAL_H */