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
Hi,
We are using the library in our application and have encountered an issue. Our devices operate at a baud rate of 921600, but it seems that the maximum baud rate supported by the library is 256000.
When we attempt to send long commands at 921600 baud, the commands are being truncated. We suspect this might be due to a buffer overflow.
Could you please confirm if this is the case and let us know if it's possible to address this issue? Your assistance would be greatly appreciated.
Thank you!
Edit: as mentioned in #177 this issue as reported occurs on Windows.
Having a look into jssc code, to me it seems that the underlying implementations already support 921600 (see the two jssc.cpp files). There is just no constant defined on java side for it.
Maybe it's worth a try to pass the baud rate as a naked int. But make sure to check the returned value for errors. Maybe this could give us a hint. Disclaimer: I did not try this myself ever. So I do not know if this works.
Maybe it's worth a try to pass the baud rate as a naked int. But make sure to check the returned value for errors. Maybe this could give us a hint. Disclaimer: I did not try this myself ever. So I do not know if this works.
Just updating this thread with information gathered from #177, quoting:
... we [do] use [the] setParam function and provide any baud rate parameter they choose, not just the predefined ones in [this] library.
However, we've encountered an issue when users send very long commands (via the writeBytes function) at 921600 baud. The commands are being truncated even if they use rts/cts flow control.(when the command are with regular size the command are sent fine, for example a command that truncated has 980 characters).
Our OS is windows.
Activity
Add java constant for non-standard baud rate 921600
hiddenalpha commentedon Nov 28, 2024
Having a look into jssc code, to me it seems that the underlying implementations already support 921600 (see the two jssc.cpp files). There is just no constant defined on java side for it.
Maybe it's worth a try to pass the baud rate as a naked int. But make sure to check the returned value for errors. Maybe this could give us a hint. Disclaimer: I did not try this myself ever. So I do not know if this works.
I don't know about the described truncation issue.
tresf commentedon Dec 1, 2024
Just updating this thread with information gathered from #177, quoting:
hiddenalpha commentedon Aug 1, 2025
Could this issue maybe relate to #129 ? (and therefore, indirectly to #195?)