rt1052 USB 传输速度慢

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

rt1052 USB 传输速度慢

1,969件の閲覧回数
wandongli
Contributor I

因为项目需要所以我使用SDK2.5 提供HID的参考历程进行了修改,修改为自定义设备。设备描述符的主要信息如下:

pastedImage_1.png

pastedImage_2.png

pastedImage_3.png

其中主要的修改为,将端点类型修改为bulk 模式传输。

我使用Libusb 进行上位机的开发,PC端一直读,发现速度很慢,如下:

pastedImage_4.png

PC 一直读的时候,设备端使用for一直发送如下:

pastedImage_5.png

其中一直读的时候整体的速度很慢,请教一下是我设备端发送数据的方式不对吗?导致发送很慢。

ラベル(1)
0 件の賞賛
3 返答(返信)

1,791件の閲覧回数
wandongli
Contributor I

HI 

     如你所说,我去掉printf的输出确实快很多,但是任然没有达到我预期的速度,我应该怎样做可以进一步的提高速度呢?另外请问一下我这样通过for的方式一直发是否可行,是否有更加可靠且快速的响应PC一直读的操作方法呢 ?

0 件の賞賛

1,791件の閲覧回数
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

Bulk传输最大包大小设置为64字节,通过while()循环应该会快一些。


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 件の賞賛

1,791件の閲覧回数
Hui_Ma
NXP TechSupport
NXP TechSupport

Hi,

Please mask the printf function within the while loop and try.

Wish it helps.


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 件の賞賛