You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello.
I had a problem with the delay in sending packets to the network.
The problem was related to the fact that the actual sending did not happen immediately after calling the WriteAsync function or others. This happened after the function was called again, at which point two packets were already sent.
Since we have a packet protocol, it is advisable not to do caching.
So I added: "_writeFileStream.Flush();"
In the file: "src\Hid.Net\Windows\WindowsHidHandler.cs"
in function: "public async Task WriteReportAsync(byte[] data, byte reportId, CancellationToken cancellationToken = default)"
Perhaps this is not an ideal option, and it should probably be done elsewhere in the library.
But it helped me.
Or it could be solved with some settings, I don't know for sure.
You can fix it, or explain to me how I could have done it differently.
Thank you.
The text was updated successfully, but these errors were encountered:
Hello.
I had a problem with the delay in sending packets to the network.
The problem was related to the fact that the actual sending did not happen immediately after calling the WriteAsync function or others. This happened after the function was called again, at which point two packets were already sent.
Since we have a packet protocol, it is advisable not to do caching.
So I added:
"_writeFileStream.Flush();"
In the file:
"src\Hid.Net\Windows\WindowsHidHandler.cs"
in function:
"public async Task WriteReportAsync(byte[] data, byte reportId, CancellationToken cancellationToken = default)"
Perhaps this is not an ideal option, and it should probably be done elsewhere in the library.
But it helped me.
Or it could be solved with some settings, I don't know for sure.
You can fix it, or explain to me how I could have done it differently.
Thank you.
The text was updated successfully, but these errors were encountered: