Files
kunlun/plc/halmac/inc/mac_rf.h
2024-09-28 14:24:04 +08:00

67 lines
2.1 KiB
C

/****************************************************************************
Copyright(c) 2019 by Aerospace C.Power (Chongqing) Microelectronics. ALL RIGHTS RESERVED.
This Information is proprietary to Aerospace C.Power (Chongqing) Microelectronics and MAY NOT
be copied by any method or incorporated into another program without
the express written consent of Aerospace C.Power. This Information or any portion
thereof remains the property of Aerospace C.Power. The Information contained herein
is believed to be accurate and Aerospace C.Power assumes no responsibility or
liability for its use in any way and conveys no license or title under
any patent or copyright and makes no representation or warranty that this
Information is free from patent or copyright infringement.
****************************************************************************/
#ifndef __MAC_RF_H__
#define __MAC_RF_H__
#ifdef __cplusplus
extern "C" {
#endif
/* mac rf info */
typedef struct _mac_rf {
/* RF_CHANNEL_ID_xx */
uint8_t rf_channel;
/* RF_CHANNEL_xx */
uint8_t rf_option;
uint16_t resv;
} mac_rf_t;
/*
* @breif mac_rf_init() - mac rf init.
* @param null - null.
* @return mac_rf_t * - the pointer of mac rf structure.
*/
mac_rf_t *mac_rf_init();
/*
* @breif mac_rf_set_self_option_channel() - set self rf option and channel.
* @param rf_option - rf option, PHY_RF_OPTION_xx.
* @param rf_channel - rf channel see RF_CHANNEL_ID_xx.
* @return void - void.
*/
void mac_rf_set_self_option_channel(uint8_t rf_option, uint8_t rf_channel);
/*
* @breif mac_rf_get_self_channel() - get self rf channel.
* @param void - void
* @return uint8_t - self rf channel, see RF_CHANNEL_ID_xx.
*/
uint8_t mac_rf_get_self_channel();
/*
* @breif mac_rf_get_self_option() - get self rf option.
* @param void - void
* @return uint8_t - self rf option, see RF_OPOTION_XX.
*/
uint8_t mac_rf_get_self_option();
#ifdef __cplusplus
}
#endif
#endif