关于RT1052的以太网收发方式问题

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

关于RT1052的以太网收发方式问题

Jump to solution
5,259 Views
1277185193
Contributor III

尊敬的管理者:

您好,我根据NXP提供的历程在rt1052上实现了以太网的收发,但是从实现过程中用到的fsl_enet.c和fsl_enet.h文件中无法查询到是否使用了DMA来收发以太网数据,以前做stm32的开发库函数中会有相关的结构体供开发者配置。所以想问问fsl库的以太网实现是否利用了DMA?

谢谢!

1 Solution
5,060 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

RT1050 Ethernet模块内部集成DMA模块,具体信息详见下图:

pastedImage_1.png

Ethernet通讯时是不会调用系统的edma模块,通过配置Ethernet模块内部的寄存器既可以完成uDMA设置。


Have a great day,
Mike

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

View solution in original post

7 Replies
5,061 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

RT1050 Ethernet模块内部集成DMA模块,具体信息详见下图:

pastedImage_1.png

Ethernet通讯时是不会调用系统的edma模块,通过配置Ethernet模块内部的寄存器既可以完成uDMA设置。


Have a great day,
Mike

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

5,060 Views
1277185193
Contributor III

首先,谢谢您的指导。请问关于以太网uDMA配置问题能否详细一点,因为无论是用户手册还是SDK包都没有相关的配置方法。比如如何启用它,它像通用的eDMA一样进行配置吗?恐怕并不是吧。

再次感谢您的帮助!谢谢!

0 Kudos
Reply
5,060 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

请查看参考手册Enhanced buffer descriptors这一小节,其中指出uDMA所用buffer描述符信息。

也可以参考SDK ENET驱动代码中(fsl_enet.c) ENET_SetTxBufferDescriptors() & ENET_SetRxBufferDescriptors() API 函数获取相关信息。


Have a great day,
Mike

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos
Reply
5,060 Views
1277185193
Contributor III

再次谢谢您的耐心指教,但是还是没有解决我的困惑。我仔细看了您说的章节和函数,并没有涉及到DMA的开启,难道直接配置好缓冲区uDMA就在以太网收发中被自动使用吗? 但 您之前说SDK中例程并没有用到DMA。

通常的以太网发送可以选择用 或者 不用 DMA方式。

所以还请帮忙指点一下,谢谢!

0 Kudos
Reply
5,060 Views
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

配置好ENET模块的buffer描述符后,uDMA会自动启动。一般我们在ENET模块初始化的时候就会配置buffer描述符以便使能内部的uDMA子模块。

pastedImage_1.png

i.MXRT1050 eDMA模块是一个独立的模块,需要配置并使能才可以使用。我们在这里讨论的是ENET模块内部的uDMA子模块,并非eDMA模块。

best regards,

Mike

2,005 Views
Jesse_Wang
Contributor I
您好,
请问能提供一份ENET_SetTxBufferDescriptors() & ENET_SetRxBufferDescriptors()函数初始化的例子吗?
0 Kudos
Reply
5,060 Views
1277185193
Contributor III

您解决了我的疑惑,非常感谢!!!

0 Kudos
Reply