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

USB communication related issue on C5-BTLE #329

Open
dsouzahansenfrancis opened this issue Oct 20, 2015 · 1 comment
Open

USB communication related issue on C5-BTLE #329

dsouzahansenfrancis opened this issue Oct 20, 2015 · 1 comment
Assignees

Comments

@dsouzahansenfrancis
Copy link
Contributor

To create this issue DEFAULT_EMULATED_DATA_STATUS was enabled. Thereafter when USB port was connected to PC it was found that BLE transfer speeds visibly slowed down.
Removing the USB port caused the BLE transfer to reach its initial transfer speed.
It was also found that issuing an openxc-dump command caused communication to work unaffected simultaneously when BLE and USB were connected.

@dsouzahansenfrancis dsouzahansenfrancis changed the title USB communication related issue USB communication related issue on C5-BTLE Oct 20, 2015
@dsouzahansenfrancis dsouzahansenfrancis self-assigned this Oct 20, 2015
@peplin
Copy link
Member

peplin commented Oct 20, 2015

There's a bit more background on this issue here: https://github.com/openxc/vi-firmware/blob/next/src/platform/pic32/usb.cpp#L114-L118

The short summary is that the USB API for the PIC32 (or at least the way I found to use the API) requires spinning waiting for a handle to be not busy, so if USB is connected but not trying to read data, it will slow down the main loop. There may be a way to use interrupts instead.

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