Daniel Vizcaya / Mbed OS 04_RTOS_Embebidos
Committer:
Bethory
Date:
Wed May 30 04:46:28 2018 +0000
Revision:
1:fcdb45ee95b9
Parent:
0:6ad07c9019fd
Entrega Final

Who changed what in which revision?

UserRevisionLine numberNew contents of line
Bethory 0:6ad07c9019fd 1 /*
Bethory 0:6ad07c9019fd 2 * Copyright (c) 2016-2017, Arm Limited and affiliates.
Bethory 0:6ad07c9019fd 3 * SPDX-License-Identifier: Apache-2.0
Bethory 0:6ad07c9019fd 4 *
Bethory 0:6ad07c9019fd 5 * Licensed under the Apache License, Version 2.0 (the "License");
Bethory 0:6ad07c9019fd 6 * you may not use this file except in compliance with the License.
Bethory 0:6ad07c9019fd 7 * You may obtain a copy of the License at
Bethory 0:6ad07c9019fd 8 *
Bethory 0:6ad07c9019fd 9 * http://www.apache.org/licenses/LICENSE-2.0
Bethory 0:6ad07c9019fd 10 *
Bethory 0:6ad07c9019fd 11 * Unless required by applicable law or agreed to in writing, software
Bethory 0:6ad07c9019fd 12 * distributed under the License is distributed on an "AS IS" BASIS,
Bethory 0:6ad07c9019fd 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Bethory 0:6ad07c9019fd 14 * See the License for the specific language governing permissions and
Bethory 0:6ad07c9019fd 15 * limitations under the License.
Bethory 0:6ad07c9019fd 16 */
Bethory 0:6ad07c9019fd 17
Bethory 0:6ad07c9019fd 18 /** \file ns_virtual_rf_api.h
Bethory 0:6ad07c9019fd 19 * \brief Virtual RF interface API.
Bethory 0:6ad07c9019fd 20 */
Bethory 0:6ad07c9019fd 21
Bethory 0:6ad07c9019fd 22 #ifndef NS_VIRTUAL_RF_API_H_
Bethory 0:6ad07c9019fd 23 #define NS_VIRTUAL_RF_API_H_
Bethory 0:6ad07c9019fd 24 #ifdef __cplusplus
Bethory 0:6ad07c9019fd 25 extern "C" {
Bethory 0:6ad07c9019fd 26 #endif
Bethory 0:6ad07c9019fd 27
Bethory 0:6ad07c9019fd 28 #include "platform/arm_hal_phy.h"
Bethory 0:6ad07c9019fd 29
Bethory 0:6ad07c9019fd 30
Bethory 0:6ad07c9019fd 31 /**
Bethory 0:6ad07c9019fd 32 * @brief virtual_rf_device_register Creates virtual RF device
Bethory 0:6ad07c9019fd 33 * Emulates "radio" link like the real RF driver would do it. MAC does not know the difference.
Bethory 0:6ad07c9019fd 34 * Sends and listens data to/from serial MAC.
Bethory 0:6ad07c9019fd 35 * @param link_type Link type behind virtual device
Bethory 0:6ad07c9019fd 36 * @param mtu_size Maximum transmission unit size
Bethory 0:6ad07c9019fd 37 * @return Rf driver id
Bethory 0:6ad07c9019fd 38 */
Bethory 0:6ad07c9019fd 39 int8_t virtual_rf_device_register(phy_link_type_e link_type, uint16_t mtu_size);
Bethory 0:6ad07c9019fd 40
Bethory 0:6ad07c9019fd 41 /**
Bethory 0:6ad07c9019fd 42 * @brief virtual_rf_client_register Creates virtual RF client
Bethory 0:6ad07c9019fd 43 * "Acts" in a role of upper layer for MAC (802.15.4 or ethernet) and in a role of RF driver for serial MAC.
Bethory 0:6ad07c9019fd 44 * Forwards data between serial MAC and either 802.15.4 or ethernet MAC.
Bethory 0:6ad07c9019fd 45 * @return Rf driver id
Bethory 0:6ad07c9019fd 46 */
Bethory 0:6ad07c9019fd 47 int8_t virtual_rf_client_register(void);
Bethory 0:6ad07c9019fd 48
Bethory 0:6ad07c9019fd 49
Bethory 0:6ad07c9019fd 50 #ifdef __cplusplus
Bethory 0:6ad07c9019fd 51 }
Bethory 0:6ad07c9019fd 52 #endif
Bethory 0:6ad07c9019fd 53 #endif /* NS_VIRTUAL_RF_API_H_ */