Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Setup packet occasionally hangs in lib_xud 2.2.2 #395

Closed
Zdenek151 opened this issue Jun 24, 2024 · 10 comments
Closed

Setup packet occasionally hangs in lib_xud 2.2.2 #395

Zdenek151 opened this issue Jun 24, 2024 · 10 comments

Comments

@Zdenek151
Copy link

Dear all,

I am seeking advice regarding the following problem, which is possibly relevant to lib_xud.
In our product, we are using xu216 with modified sw_usb_audio 6.15.2 and lib_xud 2.2.2. We received reports of our control software loosing connection with our device. The usb trace shows error in setup packets of the control transfers exchanged between the control software and the device.
trace
The processor core state appears to be stuck in XUD_GetBuffer_Finish.
XMOS DUMPSTATE.txt
Any idea on how to tackle this?

This issue was very hard to reproduce and apparently only happens on specific computers.

@xross
Copy link
Contributor

xross commented Jun 24, 2024

Please could you attach a full USB trace. Thanks.

@Zdenek151
Copy link
Author

@xross
Copy link
Contributor

xross commented Jun 24, 2024

Thanks.

The issue is the OUT is missing a handshake. This likely indicates a timing issue.

Can you confirm a couple things:

  • clock frequency device is running at
  • number of cores running on the tile where lib_xud is placed

@Zdenek151
Copy link
Author

Zdenek151 commented Jun 24, 2024

@xross Both tiles are running at 500MHz, usb is on tile[1] with 6 cores. XUD_Manager core is assigned 100MHz using set_core_high_priority_on().

@xross
Copy link
Contributor

xross commented Jun 24, 2024

Is there a chance you can try to reproduce with the develop branch of lib_xud? A small timing tweak was recently applied but not yet released

@Zdenek151
Copy link
Author

Ok. We can try.

@Zdenek151
Copy link
Author

@xross It looks good after a day of stress-testing. With lib_xud 2.2.2, the issue occurred after 15 minutes. Was that the RX_RISE_DELAY change?

@xross
Copy link
Contributor

xross commented Jun 26, 2024

Okay that's good news. Yes this is the main change since 2.2.2. It's a result of going back and doing more soak testing of handshaked transactions on xs2 devices. We'll make a new release very soon. It looks like it affects you due to polling from your control software.

@Zdenek151
Copy link
Author

@xross That was incredibly lucky timing for us. Thank you for the help.

@Zdenek151
Copy link
Author

Closing as resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants