⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 simple_mac.h

📁 用于WSN的PDA搜救器
💻 H
字号:
/* Description : head for mac functions.
 *
 * $Author: 王琢玉
 * $Date: 2007/02/23 
 * $Name:  simple_mac.h 
 */

#ifndef _SIMPLE_MAC_H
#define _SIMPLE_MAC_H

#ifdef   SIMPLE_MAC_GLOBALS
    #define   SIMPLE_MAC_EXT
#else    
    #define   SIMPLE_MAC_EXT   extern
#endif

#include "pub_def.h"

/********************************************
Typedefs
********************************************/





/********************************************
 Globals 
********************************************/ 
SIMPLE_MAC_EXT    UINT8  UsedSeqNum[4];
SIMPLE_MAC_EXT    UINT8  SeqCounter;
SIMPLE_MAC_EXT    UINT8  MySeqNum;




/********************************************
Prototypes
********************************************/ 

/************************************************************
Function:    void MACInit(void)

Parameter:   

Return:      
             
Description: Init the MAC.
************************************************************/
void MACInit(void);

/************************************************************
Function:    void MACTasks(void)

Parameter:   

Return:      
             
Description: check if there is any MAC task.
************************************************************/
void MACTasks(void);

/************************************************************
Function:    UINT8 MCPSDataRequest(void)

Parameter:   

Return:      Status of Tx
             
Description: One data Packet is requested to transive by NWK   
************************************************************/
UINT8 MCPSDataRequest(void);

/************************************************************
Function:    UINT8 MLMEPAValueSet(UINT8 u8PAValue)

Parameter:   u8PAValue   Value of power

Return:      Status
             
Description: Adjust the MC13192s Output power.
************************************************************/
UINT8 MLMEPAValueSet(UINT8 u8PAValue);

/************************************************************
Function:    UINT8 MLMESetChannelRequest(UINT8 u8Channel)

Parameter:   u8Channel        channel
                  0     :    2.405GHz
                  1     :    2.410GHz
                  2     :    2.415GHz
                  3     :    2.420GHz
                  4     :    2.425GHz
                  5     :    2.430GHz
                  6     :    2.435GHz
                  7     :    2.440GHz
                  8     :    2.445GHz
                  9     :    2.450GHz
                  10    :    2.455GHz
                  11    :    2.460GHz
                  12    :    2.465GHz
                  13    :    2.470GHz
                  14    :    2.475GHz
                  15    :    2.480GHz

Return:      
             
Description: Set the MC13192 operating channel
************************************************************/
void MLMESetChannelRequest(UINT8 u8Channel);

/************************************************************
Function:    UINT8 MLMERXDisableRequest(void)

Parameter:   

Return:      
             
Description: if RF is in Rx mode, change to idle 
************************************************************/
UINT8 MLMERXDisableRequest(void);

/************************************************************
Function:    UINT8 MLMESetMC13192ClockRate(UINT8 u8Freq)

Parameter:   u8Freq     Output Frequency
               0           16MHz (Recommended default)
               1            8MHz
               2            4MHz
               3            2MHz
               4            1MHz
               5            62.5kHz
               6            32.786kHz
               7            16.393kHz  
Return:      Status
             
Description: Set MC13192 CLKo frequency
************************************************************/
//void MLMESetMC13192ClockRate(UINT8 u8Freq);



#endif /* _SIMPLE_MAC_H */

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -