Closed dalmuri closed 10 months ago
Maybe due to async stream. Some people can not read data. I guessed that it's due to asynchronous data race. So I think that I should let people manage async data by themselves. And I will rewrite receive code in next version, exposing base read API without stream and removing all async read stream structure in endless loop.
I have removed readBytesOnce function and tried to fix readBytesOnListen
purge bugs.
Please try readBytesOnListen
function of version 1.1.0:
port.readBytesOnListen(16, (value) {
data = String.fromCharCodes(value);
print(data);
});
I have test new code using ESP32. I should solve this bug. So I will close this issue.
If the problem persists, please go to collection #27 . I will track it.
I just used the example code(just edited baudrate to 9600 for my device). Sending has no problem, but receiving don't work. I checked my device sent data to the app.
When I used readBytesOnce function, it read empty list.
Can anyone tell me why receiving didn't work? Does the example code works for you?