📄 niccommand.h
字号:
/*******************************************************************************
*** Note: Copy rights resevered to Beijing Pacific Linkair Communications Co.
***
*** File Name: NICCommand.h
*** Purpose : NIC Command Registers Definitions
***
*** Author : Guangzhao Tian
*** Modified : By Guangzhao Tian at 2000/9/7
***
**/
/***** ------------------ Commands --------------------------******
*** Global reset command.
*/
#define COMMAND_GLOBAL_RESET (0x0 << 0xB) /*0x0000 mustwait */
#define GLOBAL_RESET_MASK_TP_AUI_RESET BIT_0
#define GLOBAL_RESET_MASK_ENDEC_RESET BIT_1
#define GLOBAL_RESET_MASK_NETWORK_RESET BIT_2
#define GLOBAL_RESET_MASK_FIFO_RESET BIT_3
#define GLOBAL_RESET_MASK_AISM_RESET BIT_4
#define GLOBAL_RESET_MASK_HOST_RESET BIT_5
#define GLOBAL_RESET_MASK_SMB_RESET BIT_6
#define GLOBAL_RESET_MASK_VCO_RESET BIT_7
#define GLOBAL_RESET_MASK_UP_DOWN_RESET BIT_8
#define COMMAND_SELECT_REGISTER_WINDOW (0x1 << 0xB)
#define COMMAND_ENABLE_DC_CONVERTER (0x2 << 0xB)
#define COMMAND_RX_DISABLE (0x3 << 0xB)
#define COMMAND_RX_ENABLE (0x4 << 0xB)
/******Receiver reset command.*/
#define COMMAND_RX_RESET (0x5 << 0xB) /*0x2800 mustwait */
#define RX_RESET_MASK_TP_AUI_RESET BIT_0
#define RX_RESET_MASK_ENDEC_RESET BIT_1
#define RX_RESET_MASK_NETWORK_RESET BIT_2
#define RX_RESET_MASK_FIFO_RESET BIT_3
#define RX_RESET_MASK_UP_RESET BIT_8
#define COMMAND_UP_STALL ((0x6 << 0xB) | 0x0)/*0x3000 mustwait */
#define COMMAND_UP_UNSTALL ((0x6 << 0xB) | 0x1)/*0x3001*/
#define COMMAND_DOWN_STALL ((0x6 << 0xB) | 0x2)/*0x3002 mustwait */
#define COMMAND_DOWN_UNSTALL ((0x6 << 0xB) | 0x3)/*0x3003*/
#define COMMAND_TX_DONE (0x7 << 0xB)
#define COMMAND_RX_DISCARD (0x8 << 0xB)
#define COMMAND_TX_ENABLE (0x9 << 0xB)
#define COMMAND_TX_DISABLE (0xA << 0xB)
/******Transmitter reset command.*/
#define COMMAND_TX_RESET (0xB << 0xB) /*0x4800 mustwait */
#define TX_RESET_MASK_TP_AUI_RESET BIT_0
#define TX_RESET_MASK_ENDEC_RESET BIT_1
#define TX_RESET_MASK_NETWORK_RESET BIT_2
#define TX_RESET_MASK_FIFO_RESET BIT_3
#define TX_RESET_MASK_DOWN_RESET BIT_8
#define COMMAND_REQUEST_INTERRUPT (0xC << 0xB)
/**** Interrupt acknowledge command.*/
#define COMMAND_ACKNOWLEDGE_INTERRUPT (0xD << 0xB)
#define ACKNOWLEDGE_INTERRUPT_LATCH BIT_0
#define ACKNOWLEDGE_LINK_EVENT BIT_1
#define ACKNOWLEDGE_INTERRUPT_REQUESTED BIT_6
#define ACKNOWLEDGE_DOWN_COMPLETE BIT_9
#define ACKNOWLEDGE_UP_COMPLETE BIT_10
#define ACKNOWLEDGE_ALL_INTERRUPT 0x7FF
#define COMMAND_SET_INTERRUPT_ENABLE (0xE << 0xB)
#define DISABLE_ALL_INTERRUPT 0x0
#define ENABLE_ALL_INTERRUPT 0x6EE
#define COMMAND_SET_INDICATION_ENABLE (0xF << 0xB)
/******* Receive filter command.*/
#define COMMAND_SET_RX_FILTER (0x10 << 0xB)
#define RX_FILTER_INDIVIDUAL BIT_0
#define RX_FILTER_ALL_MULTICAST BIT_1
#define RX_FILTER_BROADCAST BIT_2
#define RX_FILTER_PROMISCUOUS BIT_3
#define RX_FILTER_MULTICAST_HASH BIT_4
#define COMMAND_TX_AGAIN (0x13 << 0xB)
#define COMMAND_STATISTICS_ENABLE (0x15 << 0xB)
#define COMMAND_STATISTICS_DISABLE (0x16 << 0xB)
#define COMMAND_DISABLE_DC_CONVERTER (0x17 << 0xB)
#define COMMAND_SET_HASH_FILTER_BIT (0x19 << 0xB)
#define COMMAND_TX_FIFO_BISECT (0x1B << 0xB)
/***
****** End of NICCommand.h
***/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -