Full Speed USB [ FRDM-MCXA153] : usb device not detecting detach event

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Full Speed USB [ FRDM-MCXA153] : usb device not detecting detach event

5,199 次查看
Gurunath
Contributor II

Hi, i have tested the usb cdc(single port) vcom example (frdmmcxa153_dev_cdc_vcom_bm) where it echoes back the characters received from host. I tried using a flag for device detach event in USB_DeviceCallback() function defined in application main code. It looks like there is no interrupt triggered for  detach event.

I have enabled detach event by defining macro USB_DEVICE_CONFIG_DETACH_ENABLE with value 1, but main isr function USB_DeviceKhciIsrFunction(), inside USB0_IRQHandler() is not getting called.

in main(), am trying to send message with delay and this is supposed to stop and print a debug message as flag is changed if interrupt has triggered. Please find below the attcahed images for screenshots and let me know if i need to do some configuration.

 

 

标签 (2)
0 项奖励
回复
3 回复数

5,054 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @Gurunath 

I suggest you use the below two methods.

1> Please use the attached signal from below parameters to detect attach (1) or de-attach(0)

g_UsbDeviceHidGeneric.attach = 0U;

 

2> Enable P2_12 as VBUS detection, and check the "SESS_VLD" bit status in CONTROL register as below

Alice_Yang_0-1723695202084.png

 

BR

Alice

 

 

0 项奖励
回复

5,184 次查看
Gurunath
Contributor II
example is from frdm-mcxa153 sdk
0 项奖励
回复

5,071 次查看
Alice_Yang
NXP TechSupport
NXP TechSupport

Hello @Gurunath 

Thanks for your patience.

The same on my side. I will check it with internal. Then reply you .ASAP. 

 

BR

Alice

 

0 项奖励
回复