Cypress技术william hill官网
直播中

张珊珊

7年用户 133经验值
私信 关注
[问答]

USBUART(CDC)PSOC5LP检测USB断线

大家好,
在阅读william hill官网 和例子,并在几个问题的USB驱动程序,现在我能够使用USPUART(CDC)接口与PSoC5LP!
它仍然只是一个问题:管理USB电缆的连接/断开。
我读KBA210620:
HTTP://OrgIn www. CyPur.com /知识基础文章/故障排除PSOC-3-PSOC-4-L系列和PSOC-5LP-USB设计-KBA210620
此文档建议监视VBUS线路以检测断开事件。
但是,在我目前的设计中,我不能监控VBUS线(自供电-没有VBUS)。
我做了一些实验,但我不走运。
有人知道在没有监视VBUS线路的情况下检测USB断开(USPADAR-CDC)的解决方案吗?
提前感谢大家;
PS:UBART组件数据表V.3.20没有定义UBuTARGETGETFIONtiON()API

以上来自于百度翻译


     以下为原文
  Hi to all,
after reading forum and examples and after a couple of problems regarding USB drivers, now I am able to use USBUART (CDC) interface with PSoC5LP!

It remains only a problem: manage the connection/disconnection of the USB cable.

I read KBA210620:
[url=https://community.cypress.com/external-link.jspa?url=http%3A%2F%2Forigin-www.cypress.com%2Fknowledge-base-article%2Ftroubleshooting-psoc-3-psoc-4-l-series-and-psoc-5lp-u***-designs-kba210620]http://origin-www.cypress.com/knowledge-base-article/troubleshooting-psoc-3-psoc-4-l-series-and-psoc-5lp-u***-designs-kba210620[/url]
This document suggest to monitor the VBUS line to detect the disconnection event.

But, in my current design, I cannot monitor the VBUS line (SELF POWERED - NO VBUS).

I did a bit of experiments but I was not lucky.
There is someone that knows a solution to detect USB disconnection (USBUART - CDC) without monitoring the VBUS line?


Thank you in advance to all ;-)

PS: UBUART component datasheet v.3.20 does not define USBUART_GetConfiguration() API

回帖(3)

鲁玉萍

2018-10-9 11:25:18
您可以使用UBFSXCuffActuvio()。
谢谢,
希马

以上来自于百度翻译


     以下为原文
  You can use the USBFS_CheckActivity().
 
Thanks,
Hima
举报

张珊珊

2018-10-9 11:37:31
引用: 60user67 发表于 2018-10-4 11:28
您可以使用UBFSXCuffActuvio()。
谢谢,
希马

嗨,希玛,
非常感谢你的回复。
但是,不幸的是,由于我使用的是UBUART,所以在我的环境中不存在函数UBFSXCuffActuvio()。
相反,它存在函数UBUARTAR.CuffActuvio(),但是它没有在数据表中被记录!!!!
为什么这个函数没有被记录?
但是,现在我将尝试测试这个函数。
谢谢,
格拉齐亚诺。

以上来自于百度翻译


     以下为原文
  Hi hima,
thank you very much for your reply.
 
But, unfortunately, the function USBFS_CheckActivity() does not exist in my environment because I am using USBUART.
 
Instead it exists the function USBUART_CheckActivity() but it is not documented inside the datasheet!!!
 
Why this function is not documented?
 
However, now I will try to test this function.
 
Thanks,
Graziano.
举报

徐小婷

2018-10-9 11:50:19
引用: droidhw 发表于 2018-10-4 11:40
嗨,希玛,
非常感谢你的回复。
但是,不幸的是,由于我使用的是UBUART,所以在我的环境中不存在函数UBFSXCuffActuvio()。

函数返回总线的活动状态。它清除硬件状态以在该函数的下一次调用上提供更新状态。它提供了一种确定USB总线活动是否发生的方法。应用程序应该使用这个函数来确定USB中断条件是否满足。

以上来自于百度翻译


     以下为原文
  USBUART_CheckActivity() function returns the activity status of the bus. It clears the hardware status to provide updated status on the next call of this function. It provides a way to determine whether any USB bus activity occurred. The application should use this function to determine if the USB suspend conditions are met.
举报

更多回帖

发帖
×
20
完善资料,
赚取积分