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

ANTUSB2 Not receiving any data (Windows, Linux) #20

Open
purpl3F0x opened this issue Aug 17, 2021 · 1 comment
Open

ANTUSB2 Not receiving any data (Windows, Linux) #20

purpl3F0x opened this issue Aug 17, 2021 · 1 comment

Comments

@purpl3F0x
Copy link

Hello I'm trying to run the antdump example. I used both Linux and windows, on both it doesn't seem to receive any data

On windows I get:

2021/08/17 12:42:06 Starting Device
2021/08/17 12:42:06 Opening USB device
... then the app just stays there

On Linux:

2021/08/17 14:53:06 Starting Device
2021/08/17 14:53:06 Opening USB device
2021/08/17 14:53:06 Loop Started
2021/08/17 14:53:06 Loop stopped!
2021/08/17 14:53:06 Closing USB device
2021/08/17 14:53:07 handle_events: error: libusb: interrupted [code -10]
2021/08/17 14:53:14 handle_events: error: libusb: interrupted [code -10]
...

(should't here the app terminate since stuff seem to be closing ??)

I also took a peak on the dongle's traffic packages with USBTrace on windows and I think no data is being sent out.

My device is an ant+ environment sensor so 4Hz(8192) (which is the default channel frequency - your lib doesn't expose that Setting) should be working with the configuration done

@purpl3F0x purpl3F0x changed the title USBAnt2 Not receiving any data (Windows or Linux) ANTUSB2 Not receiving any data (Windows or Linux) Aug 17, 2021
@purpl3F0x purpl3F0x changed the title ANTUSB2 Not receiving any data (Windows or Linux) ANTUSB2 Not receiving any data (Windows, Linux) Aug 17, 2021
@purpl3F0x
Copy link
Author

purpl3F0x commented Aug 17, 2021

I managed to get it working under Linux. Troubleshooting it a bit, I found that libusb was reporting that device was busy 'cause the kernel driver was loaded. Adding a

dev.device.SetAutoDetach(true);     /*After line 31 usb.go*/ 

on the Open() of the usb.go seems to solve the problem

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

1 participant