/* * Copyright (C) 2021 The Android Open Source Project * * Copyright 2021 NXP. * * Licensed under the Apache License, Version 2.0 (the "License"); * You may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef _UWB_RFTEST_NATIVE_MANAGER_H_ #define _UWB_RFTEST_NATIVE_MANAGER_H_ namespace android { typedef struct { uint8_t status; ///< Status uint32_t attempts; ///< No. of RX attempts uint32_t ACQ_detect; ///< No. of times signal was detected uint32_t ACQ_rejects; ///< No. of times signal was rejected uint32_t RX_fail; ///< No. of times RX did not go beyond ACQ stage uint32_t sync_cir_ready; ///< No. of times sync CIR ready event was received uint32_t sfd_fail; ///< No. of time RX was stuck at either ACQ detect or sync ///< CIR ready uint32_t sfd_found; ///< No. of times SFD was found uint32_t phr_dec_error; ///< No. of times PHR decode failed uint32_t phr_bit_error; ///< No. of times PHR bits in error uint32_t psdu_dec_error; ///< No. of times payload decode failed uint32_t psdu_bit_error; ///< No. of times payload bits in error uint32_t sts_found; ///< No. of times STS detection was successful uint32_t eof; ///< No. of times end of frame event was triggered } tPER_RX_DATA; typedef struct { uint8_t status; //< Status uint32_t txts_int; //< Integer part of timestamp in 1/124.8 us resolution uint16_t txts_frac; //< Fractional part of timestamp in 1/124.8/512 µs resolution uint32_t rxts_int; //< Integer part of timestamp in 1/124.8 us resolution uint16_t rxts_frac; //< Fractional part of timestamp in 1/124.8/512 us resolution uint16_t aoa_azimuth; //< AoA Azimuth in degrees and it is signed value in // Q9.7 format uint16_t aoa_elevation; //< AoA Elevation in degrees and it is signed value // in Q9.7 format uint16_t phr; //< Received PHR (bits 0-12 as per IEEE spec) uint16_t psdu_data_length; //