完善资料让更多小伙伴认识你,还能领取20积分哦, 立即完善>
你好,
我正试图了解当FX2有电源但USB被拔出后再插入的时候会发生什么。我们的固件使用VANDYAX示例作为骨架代码。我原本以为,如果用户拔出USB电缆并将它插回(电源是单独提供的,而不是通过USB),那么TDyIn()将被再次调用。然而,事实并非如此。我知道,当USB被拔出时,FX2将进入休眠模式,当USB电缆***入到主机时,它会“唤醒”。 我的问题是,考虑到我们的FX2和FPGA是如何集成的,我需要发送一个信号从微控制器来重置FPGA当这个重新枚举事件发生,我不知道什么样的程序将被调用一次,当USB电缆插入。我发现,当“重新枚举一个新设备”时,调用TDyIn()的地方,但显然在连接到主机的USB电缆中插入和插入不是那个事件吗? 欢迎任何智慧! 大肆宣传 以上来自于百度翻译 以下为原文 Hi, I'm trying to understand exactly what happens when the FX2 has power but the USB is unplugged and then re-plugged back in. Our firmware uses the vend_ax example as skeleton code. I had thought originally that if the user unplugs the USB cable and plugs it back in (power is supplied separately; not through USB) that TD_Init() would be called again. However, that appears to not be the case. I understand that when the USB is unplugged the FX2 will go into sleep mode and that it "wakes up" when the USB cable to the host is plugged back in. My issue is, given how our FX2 and FPGA are integrated, I need to send a signal from the microcontroller to reset the FPGA when this re-enumeration event happens and I'm not sure what routine will be called once when the USB cable is inserted. I found somewhere that TD_Init() is called when "re-enumerating a new device" but apparently unplugging and plugging in USB cable connecting to the host is not that event? Any wisdom welcome! -Hyped |
|
相关推荐
3个回答
|
|
你好,
当FX2在自供电模式(即外部电源;而不是VBUS)中工作时,如果每当发生重发时要中断FPGA,就可以使用SETICONF请求。枚举设置完成后,主机将发出配置请求。当接收到SETICONF请求时,您可以设置一些标志或通知FPGA。 或者您甚至可以使用GPIO来监视TDYPURBO中的VBUS。 当做, 加亚特里 以上来自于百度翻译 以下为原文 Hi, When FX2 is operating in self powered mode (i.e. external power supply; not VBUS), if you want to interrupt FPGA whenever renumeration happens, you can make use of SET_CONF request. Upon completion of enumeration SET_CONFIGURATION request will be issued by the host. You can set some flag or notify the FPGA when SET_CONF request is received. Or you can even use a GPIO to monitor VBUS in TD_POLL. Regards, Gayathri |
|
|
|
嗨,Gayathri,
谢谢你的回复!因此,在DavyAx.c中有一个DRUSET配置存根: 当接收到SET配置命令时,BooDr.StStaseCuffic(空隙)/被调用{配置=SETUPDATAT(2);返回(true);/ /由用户代码}处理,我应该能够在这里添加FPGA重置命令,对吗?出于好奇,我想知道是否可以在FW.C唤醒中断处理程序存根中包括FPGA复位://唤醒唤醒处理程序空格ReuMeMyISR(空隙)中断WKUPUVECT{{EZUBS}CURRESRSMRQ();谢谢!最好的,史葛 以上来自于百度翻译 以下为原文 Hi Gayathri, Thanks for your response! So in vend_ax.c there is a DR_SetConfiguration stub: BOOL DR_SetConfiguration(void) // Called when a Set Configuration command is received{ Configuration = SETUPDAT[2]; return(TRUE); // Handled by user code} I should be able to just add the FPGA reset command in here, correct? Out of curiosity, I was wondering whether one could include the FPGA reset in the fw.c wake-up interrupt handler stub: // Wake-up interrupt handler void resume_isr(void) interrupt WKUP_VECT { EZUSB_CLEAR_RSMIRQ(); } Thanks! Best, Scott |
|
|
|
你好,
到目前为止,我还没有尝试唤醒中断处理程序。我得检查一下。SET配置请求的另一个OPRION工作了吗? 当做, 加亚特里 以上来自于百度翻译 以下为原文 Hi, I have not tried the wakeup interrupt handler so far. I will have to check on that. Did the other oprion of Set config request work? Regards, Gayathri |
|
|
|
只有小组成员才能发言,加入小组>>
752个成员聚集在这个小组
加入小组2069 浏览 1 评论
1826 浏览 1 评论
3639 浏览 1 评论
请问可以直接使用来自FX2LP固件的端点向主机FIFO写入数据吗?
1760 浏览 6 评论
1510 浏览 1 评论
CY8C4025LQI在程序中调用函数,通过示波器观察SCL引脚波形,无法将pin0.4(SCL)下拉是什么原因导致?
508浏览 2评论
CYUSB3065焊接到USB3.0 TYPE-B口的焊接触点就无法使用是什么原因导致的?
358浏览 2评论
CX3连接Camera修改分辨率之后,播放器无法播出camera的画面怎么解决?
410浏览 2评论
357浏览 2评论
使用stm32+cyw43438 wifi驱动whd,WHD驱动固件加载失败的原因?
855浏览 2评论
小黑屋| 手机版| Archiver| 电子发烧友 ( 湘ICP备2023018690号 )
GMT+8, 2024-11-22 20:09 , Processed in 0.929538 second(s), Total 80, Slave 64 queries .
Powered by 电子发烧友网
© 2015 bbs.elecfans.com
关注我们的微信
下载发烧友APP
电子发烧友观察
版权所有 © 湖南华秋数字科技有限公司
电子发烧友 (电路图) 湘公网安备 43011202000918 号 电信与信息服务业务经营许可证:合字B2-20210191 工商网监 湘ICP备2023018690号