Closed Aukstkalnis closed 4 years ago
Hi @Aukstkalnis sorry for the long delay answering this one.
May you provide a way to reproduce the problem? May you log the output of the read? something like:
n, err = p.Read(buf)
fmt.Printf("READ (%d)> %+v\n", n, buf[:n])
May you describe your application in a little more detail? in particular what kind of data is the device sending through the serial port?
Well, in device I read 2000 ADC values to buffer and send them to PC when it is full in format '%.2f/%.2f '...'\r'. I can't take log now because I do not have time at for now. Communication is done via FTDI. I looked at USB communication and there are bytes coming from device, but software do not read them :/ To reproduce the problem I think you need some FTDI device that you can program to send 2k float values in format '%.2f/%.2f '...'\r' each 4s and see what happens. Maybe that this has to do something with USB devices...
Hi @Aukstkalnis without an example to reproduce the problem I'm lost...
I'm closing the issue since a lot of time has passed and I guess you have found a workaround by yourself in the meantime.
BTW If you're still interested don't hesitate to open a new issue but, please, provide a program that helps to reproduce the problem, this is a very fundamental piece of information to get the issue properly fixed.
Device constantly sends data to host. Upon reading first time, text is read that device never sends and second read blocks forever. But if I use "github.com/tarm/serial", everything works ok. My OS is windows 10 x64. My code: