免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
12下一页
最近访问板块 发新帖
查看: 6376 | 回复: 18
打印 上一主题 下一主题

SMSC LAN91C111 Ethernet Driver Development [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2011-03-03 17:13 |只看该作者 |倒序浏览
本帖最后由 voidjackjiang 于 2011-03-04 10:58 编辑

Description:
     Ethernet Chip: SMSC LAN91C111
     SoC: OMAP3530
     Environment: g-bios, linux kernel

论坛徽章:
0
2 [报告]
发表于 2011-03-04 10:17 |只看该作者
【Owin】设备ID还没有读出来。
昨天看了Omap3530的原理图,找到了地址、数据、读写和片选pin脚。
阅读了LAN91C的datasheet,分析了block diagram,初步了解了设备的组成拓扑结构,并进一步的分析了pin脚的functions,对结构中的PHY、MAC关系,DMA和MMU的作用有了更深刻的认识。

论坛徽章:
0
3 [报告]
发表于 2011-03-04 10:20 |只看该作者
工作进展:
       根据LAN91C111和omap3530的 datasheet 配置GPMC_CONFIGx_5,enable ncs5, 选择16位模式,计算出片选区域的基址,然后选择LAN91C111的BANK3模式,读取REV数值。
结果为0,读取失败。
      原因分析:基址选择有误。
      提问:LAN91C111中944页的gpmc_we(oe)是否要配置,如何配置。

论坛徽章:
0
4 [报告]
发表于 2011-03-04 10:23 |只看该作者
第一天进展:
1:导读了omap3530,LAN91C111 datasheet;
2:理清了SMSC LAN91C111内部原理结构(MAC,PHY,MII,EEPROM),及操作方式;
3:明白了SOC是怎样片选到LAN91C111,及如何控制访问到LAN91C111;
4:设备ID尚未读出,估计读写方式错误。

论坛徽章:
0
5 [报告]
发表于 2011-03-04 10:43 |只看该作者
Michael:

omap3530 register配置:
GPMC_CONFIG: 配置LIMITEDADDRESS
GPMC_CONFIG1_i: 配置MUXADDDATA,DEVICETYPE,DEVICESIZE
GPMC_CONFIG7_i: 配置MASKADDRESS(128M),CSVALID(enable)
GPMC_PREFETCH_CONFIG1: 配置ENGINECSSELECTOR(cs5)

对于LAN91C111,通过配置Bank select Register选择Bank3, 读取Revision Register即可到ID,但现在读取的值为0,不知何处出的问题,正在查找......

论坛徽章:
0
6 [报告]
发表于 2011-03-04 10:46 |只看该作者
The progress of project:

1.Read OMAP353x technical reference manual and LAN91C111 spec.

2.Analyze the block diagram of LAN91C.

3.Analyze the connection of the sock and the ethernet device, but not finished.

4.Ready to read the id of LAN91C, not finished.

论坛徽章:
0
7 [报告]
发表于 2011-03-04 17:19 |只看该作者
本帖最后由 louismaxwit 于 2011-03-05 14:49 编辑

Development Environment:

Ethernet chip: SMSC LAN91C111

SOC: OMAP3530

Environment: g-bios




The progress of project:

1.Finish reading ID of LAN91C.

  According to the omap353x and LAN91C specs, we could found that followings:

  a. The addressable of memory which GPMC controlled have been divided into eight banks.

  b. try to chip-select bank1, so we should choose to set GPMC_CONFIG1_1 register and GPMC_CONFIG7_1 register.

  c. set the chip-select base address and region size in GPMC_CONFIG7_1 register.

  d. set the bank number which we choosed from MAC registers into the bank select register.

  e. read the chip id from the corresponding register in LAN91C.

论坛徽章:
0
8 [报告]
发表于 2011-03-05 09:46 |只看该作者
读了n遍LAN91C111 Datasheet,仍没有发现如何读取PHY ID。。。。。。

论坛徽章:
0
9 [报告]
发表于 2011-03-05 19:45 |只看该作者
Development Environment:

Ethernet chip: SMSC LAN91C111

SOC: OMAP3530

Environment: g-bios




The progress of project:

  Continued reading LAN91C spec ......

论坛徽章:
0
10 [报告]
发表于 2011-03-08 09:41 |只看该作者
终于可以回帖了。现在已经实现了数据包的接收,PHY ID暂时先不读了
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP