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

📄 ieee_address.h

📁 Freescale ARM11系列CPU MX31的WINCE 5.0下的BSP
💻 H
字号:
//---------------------------------------------------------------------------
//Copyright (C) 2006, Freescale Semiconductor, Inc. All Rights Reserved.
// THIS SOURCE CODE, AND ITS USE AND DISTRIBUTION, IS SUBJECT TO THE TERMS
// AND CONDITIONS OF THE APPLICABLE LICENSE AGREEMENT 
//--------------------------------------------------------------------------
//
// File:  ieee_address.h
// Header file for platform specific SDIO WLAN functions
//------------------------------------------------------------------------------

#ifndef __IEEE_ADDRESS_H
#define __IEEE_ADDRESS_H

#if defined(_MSC_VER)
    #pragma pack(push,1)
    #define PREPACK
    #define POSTPACK
#elif defined(__CC_ARM)
    #define PREPACK     __packed
    #define POSTPACK
#elif defined(__GNUC__)
    #define PREPACK
    #define POSTPACK    __attribute__ ((__packed__)) 
#else
    #error need to figure out packing syntax
#endif

/* Length of IEEE address (bytes) */
#define IEEE_ADDR_LEN                   (6)

/* This type is used for Source and Destination MAC addresses and also as   */
/* unique identifiers for Stations and Networks.                            */

PREPACK typedef struct IEEE_ADDR
{
    uint8 au8Addr[IEEE_ADDR_LEN];
} POSTPACK IEEE_ADDR;

#define IEEE_ADDR_CONTROL_BITS_MASK     (0x03) /* masks out bottom two bits */
#define IEEE_ADDR_UNIVERSAL             (0x02) /* the universal/local bit */
#define IEEE_ADDR_GROUP                 (0x01) /* the group/individual bit */

bool boIEEE_ADDR_IsEqual(const IEEE_ADDR *, const IEEE_ADDR *);
bool boIEEE_ADDR_IsBroadcast(const IEEE_ADDR *);

#define boIEEE_ADDR_IsMulticast(psIEEEaddrDest) \
    ((psIEEEaddrDest != NULL) && (((psIEEEaddrDest)->au8Addr[0] & IEEE_ADDR_GROUP) != 0))

#if defined(_MSC_VER)
    #pragma pack(pop)
#endif

#endif

⌨️ 快捷键说明

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