Lines Matching refs:berTlv
99 std::vector<uint8_t> berTlv) { in getDataFromBerTlv() argument
100 if (berTlv.empty()) { in getDataFromBerTlv()
103 size_t lengthTag = berTlv[0]; in getDataFromBerTlv()
104 LOG(DEBUG) << "decodeBerTlv: berTlv[0]=" << berTlv[0]; in getDataFromBerTlv()
109 if (lengthTag < 0x80 && berTlv.size() == (lengthTag + 1)) { in getDataFromBerTlv()
110 return std::vector<uint8_t>(berTlv.begin() + 1, berTlv.end()); in getDataFromBerTlv()
111 } else if (lengthTag == 0x81 && berTlv.size() > 2) { in getDataFromBerTlv()
112 size_t length = berTlv[1]; in getDataFromBerTlv()
113 if ((length + 2) == berTlv.size()) { in getDataFromBerTlv()
114 return std::vector<uint8_t>(berTlv.begin() + 2, berTlv.end()); in getDataFromBerTlv()
116 } else if (lengthTag == 0x82 && berTlv.size() > 3) { in getDataFromBerTlv()
117 size_t length = ((berTlv[1] << 8) | berTlv[2]); in getDataFromBerTlv()
118 if ((length + 3) == berTlv.size()) { in getDataFromBerTlv()
119 return std::vector<uint8_t>(berTlv.begin() + 3, berTlv.end()); in getDataFromBerTlv()
121 } else if (lengthTag == 0x83 && berTlv.size() > 4) { in getDataFromBerTlv()
122 size_t length = (berTlv[1] << 16) | (berTlv[2] << 8) | berTlv[3]; in getDataFromBerTlv()
123 if ((length + 4) == berTlv.size()) { in getDataFromBerTlv()
124 return std::vector<uint8_t>(berTlv.begin() + 4, berTlv.end()); in getDataFromBerTlv()
126 } else if (lengthTag == 0x84 && berTlv.size() > 5) { in getDataFromBerTlv()
128 (berTlv[1] << 24) | (berTlv[2] << 16) | (berTlv[3] << 8) | berTlv[4]; in getDataFromBerTlv()
129 if ((length + 5) == berTlv.size()) { in getDataFromBerTlv()
130 return std::vector<uint8_t>(berTlv.begin() + 5, berTlv.end()); in getDataFromBerTlv()
179 std::vector<uint8_t> berTlv(event_buff + berTlvStart, in nfaHciCallback() local
182 data = getInstance().getDataFromBerTlv(berTlv); in nfaHciCallback()