1 /*
2  * Copyright (c) 2020 - 2023, Nordic Semiconductor ASA
3  * All rights reserved.
4  *
5  * SPDX-License-Identifier: BSD-3-Clause
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions are met:
9  *
10  * 1. Redistributions of source code must retain the above copyright notice, this
11  *    list of conditions and the following disclaimer.
12  *
13  * 2. Redistributions in binary form must reproduce the above copyright
14  *    notice, this list of conditions and the following disclaimer in the
15  *    documentation and/or other materials provided with the distribution.
16  *
17  * 3. Neither the name of Nordic Semiconductor ASA nor the names of its
18  *    contributors may be used to endorse or promote products derived from this
19  *    software without specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23  * IMPLIED WARRANTIES OF MERCHANTABILITY, AND FITNESS FOR A PARTICULAR PURPOSE
24  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
25  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31  * POSSIBILITY OF SUCH DAMAGE.
32  *
33  */
34 
35 /**
36  * @brief 802.15.4 antenna diversity module.
37  */
38 
39 #include "nrf_802154_sl_ant_div.h"
40 
41 #ifdef __cplusplus
42 extern "C" {
43 #endif
44 
nrf_802154_sl_ant_div_cfg_set(const nrf_802154_sl_ant_div_cfg_t * p_cfg)45 void nrf_802154_sl_ant_div_cfg_set(const nrf_802154_sl_ant_div_cfg_t * p_cfg)
46 {
47     (void)p_cfg;
48 }
49 
nrf_802154_sl_ant_div_cfg_get(nrf_802154_sl_ant_div_cfg_t * p_cfg)50 bool nrf_802154_sl_ant_div_cfg_get(nrf_802154_sl_ant_div_cfg_t * p_cfg)
51 {
52     (void)p_cfg;
53 
54     return false;
55 }
56 
nrf_802154_sl_ant_div_cfg_mode_set(nrf_802154_sl_ant_div_op_t op,nrf_802154_sl_ant_div_mode_t mode)57 bool nrf_802154_sl_ant_div_cfg_mode_set(nrf_802154_sl_ant_div_op_t   op,
58                                         nrf_802154_sl_ant_div_mode_t mode)
59 {
60     (void)op;
61     (void)mode;
62 
63     return false;
64 }
65 
nrf_802154_sl_ant_div_cfg_mode_get(nrf_802154_sl_ant_div_op_t op)66 nrf_802154_sl_ant_div_mode_t nrf_802154_sl_ant_div_cfg_mode_get(nrf_802154_sl_ant_div_op_t op)
67 {
68     (void)op;
69 
70     return NRF_802154_SL_ANT_DIV_MODE_DISABLED;
71 }
72 
nrf_802154_sl_ant_div_cfg_antenna_set(nrf_802154_sl_ant_div_op_t op,nrf_802154_sl_ant_div_antenna_t antenna)73 bool nrf_802154_sl_ant_div_cfg_antenna_set(nrf_802154_sl_ant_div_op_t      op,
74                                            nrf_802154_sl_ant_div_antenna_t antenna)
75 {
76     (void)op;
77     (void)antenna;
78 
79     return false;
80 }
81 
nrf_802154_sl_ant_div_cfg_antenna_get(nrf_802154_sl_ant_div_op_t op)82 nrf_802154_sl_ant_div_antenna_t nrf_802154_sl_ant_div_cfg_antenna_get(nrf_802154_sl_ant_div_op_t op)
83 {
84     (void)op;
85 
86     return NRF_802154_SL_ANT_DIV_ANTENNA_NONE;
87 }
88 
nrf_802154_sl_ant_div_init(void)89 bool nrf_802154_sl_ant_div_init(void)
90 {
91     return false;
92 }
93 
nrf_802154_sl_ant_div_antenna_set(nrf_802154_sl_ant_div_antenna_t antenna)94 bool nrf_802154_sl_ant_div_antenna_set(nrf_802154_sl_ant_div_antenna_t antenna)
95 {
96     (void)antenna;
97 
98     return false;
99 }
100 
nrf_802154_sl_ant_div_antenna_get(void)101 nrf_802154_sl_ant_div_antenna_t nrf_802154_sl_ant_div_antenna_get(void)
102 {
103     return NRF_802154_SL_ANT_DIV_ANTENNA_NONE;
104 }
105 
nrf_802154_sl_ant_div_last_rx_best_antenna_get(void)106 nrf_802154_sl_ant_div_antenna_t nrf_802154_sl_ant_div_last_rx_best_antenna_get(void)
107 {
108     return NRF_802154_SL_ANT_DIV_ANTENNA_NONE;
109 }
110 
nrf_802154_sl_ant_div_rx_frame_started_notify(void)111 bool nrf_802154_sl_ant_div_rx_frame_started_notify(void)
112 {
113     return false;
114 }
115 
nrf_802154_sl_ant_div_rx_frame_received_notify(void)116 void nrf_802154_sl_ant_div_rx_frame_received_notify(void)
117 {
118     // Intenionally empty
119 }
120 
nrf_802154_sl_ant_div_rx_aborted_notify(void)121 void nrf_802154_sl_ant_div_rx_aborted_notify(void)
122 {
123     // Intentionally empty
124 }
125 
nrf_802154_sl_ant_div_rx_preamble_timeout_notify(void)126 void nrf_802154_sl_ant_div_rx_preamble_timeout_notify(void)
127 {
128     // Intentionally empty
129 }
130 
nrf_802154_sl_ant_div_rx_preamble_detected_notify(void)131 void nrf_802154_sl_ant_div_rx_preamble_detected_notify(void)
132 {
133     // Intentionally empty
134 }
135 
nrf_802154_sl_ant_div_energy_detection_requested_notify(uint32_t * p_ed_time)136 void nrf_802154_sl_ant_div_energy_detection_requested_notify(uint32_t * p_ed_time)
137 {
138     (void)p_ed_time;
139 }
140 
nrf_802154_sl_ant_div_energy_detection_aborted_notify(void)141 void nrf_802154_sl_ant_div_energy_detection_aborted_notify(void)
142 {
143     // Intentionally empty
144 }
145 
nrf_802154_sl_ant_div_energy_detection_finished_notify(void)146 bool nrf_802154_sl_ant_div_energy_detection_finished_notify(void)
147 {
148     return false;
149 }
150 
nrf_802154_sl_ant_div_rx_started_notify(void)151 void nrf_802154_sl_ant_div_rx_started_notify(void)
152 {
153     // Intentionally empty
154 }
155 
nrf_802154_sl_ant_div_txack_notify(void)156 void nrf_802154_sl_ant_div_txack_notify(void)
157 {
158     // Intentionally empty
159 }
160 
161 #ifdef __cplusplus
162 }
163 #endif
164