-
Notifications
You must be signed in to change notification settings - Fork 2
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
Only getting 1 byte in readAsync #5
Comments
Sorry mate - readAsync is really broken at the moment, and I sort of entirely forgot about it I might take a look at it sometime soon but from past attempts and my minimal experience I haven't had the best of luck, for now it might be best to readSync repeatedly either in a seperate thread on the nodejs side, or just in small enough sizes that it doesn't interfere with the main thread. Sorry about the hassle, I can understand the frustration but I simply don't have the answers right now. Best regards |
@Arkanic Got it. Just concerned that I'll miss data from the device if I do the sync version. But maybe that isn't as big of a concern. |
That is actually a valid concern I haven't thought about, again i'll take a look at some point but for now it remains unresolved. |
update: ffi-napi seems to have been abandoned entirely, last release to npm was 3 years ago, and it doesn't build on modern versions of node anymore - which was the whole point of this library |
Just reworked the entire backend with a new library, it works on the latest version of node now cheers |
The following code only prints
1
to the console a bunch of times.However, the following code prints 262144 to the console a bunch of times.
Why would
readSync
give me the data length I want, whereasreadAsync
does not?The text was updated successfully, but these errors were encountered: