本版名称: 嵌入式

版       主: daicheng, richiefang, wanghongyang, jxb01033016, chenzhufly

EEWORLD欢迎您,请先注册登录

DM9000的基地址是多少??

DM9000的基地址是多少??

DM9000连接在bank4;CMD连接在ADD2脚
bank4物理地址与虚拟地址对应关系:
DCD 0x88000000, 0x20000000, 32 ; 32 MB SROM(SRAM/ROM) BANK 4

#define DM9000DBG_IOBASE (0xXXXXXXXX)
#define DM9000DBG_MEMBASE (0xXXXXXXXX)
复制内容到剪贴板
代码:

相关代码:
BOOL InitEthDevice(PBOOT_CFG pBootCfg)
{
USHORT wMAC[3];
PBYTE pBaseIOAddress = NULL;
DWORD dwMultiplier = 0;
// Boot CS8900.
//
if (!pBaseIOAddress)
{
// Use the MAC address programmed into flash by the user.
//
memcpy(wMAC, pBootCfg->EdbgAddr.wMAC, 6);

pfnEDbgInit = DM9000DBG_Init;
pfnEDbgGetFrame = DM9000DBG_GetFrame;
pfnEDbgSendFrame = DM9000DBG_SendFrame;

pBaseIOAddress = (PBYTE)DM9000DBG_IOBASE;
dwMultiplier = DM9000DBG_MEMBASE;

memcpy(pDriverGlobals->eth.TargetAddr.wMAC, pBootCfg->EdbgAddr.wMAC, 6);
pDriverGlobals->misc.EbootDevice = (UCHAR)DOWNLOAD_DEVICE_CS8900;
}

// Initialize the built-in Ethenet controller.
//
if (!pfnEDbgInit((PBYTE)pBaseIOAddress, dwMultiplier, wMAC))
{
EdbgOutputDebugString(\"ERROR: InitEthDevice: Failed to initialize Ethernet controller.\r\n\");
return(FALSE);
}
。。。。。。
}
DM9000DBG_IOBASE应该为多少呢??
0x88000000?0x88000300还是89000300???

DM9000DBG_MEMBASE是做什么的??大小为0x88000000???
哪位大侠,能否讲解下??

TOP↑

我看看俺的BSP再告诉你,,,

TOP↑

引用:
引用 1 楼 iwillbeback008 的回复:
我看看俺的BSP再告诉你,,,
谢谢!!

TOP↑

[HKEY_LOCAL_MACHINE\Comm\DM9CE1\Parms]
"BusNumber"=dword:0
"BusType"=dword:1
"XmitBuffer"=dword:20
"RecvBuffer"=dword:20
"SysIntr"=dword:1a ;逻辑中断号为26~0x1a
"IrqNumber"=dword:23 ;IRQ号为35~0x23
"IoAddress"=dword:20000300 ;IO_BASE_ADDRESS,对应DM9000网卡接在BANK4中,同时INDEX port偏移量为300H;
"UseSoftwareMac"=dword:1 ;使用软件MAC地址
"SoftwareMacAddress0"=dword:20
"SoftwareMacAddress1"=dword:04
"SoftwareMacAddress2"=dword:09
"SoftwareMacAddress3"=dword:18
"SoftwareMacAddress4"=dword:00
"SoftwareMacAddress5"=dword:07

TOP↑

24小时排行榜

最近访问的版块