Skip to content
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

Allow to send and receive data from the same COM port #350

Open
max-privato opened this issue Oct 24, 2021 · 1 comment
Open

Allow to send and receive data from the same COM port #350

max-privato opened this issue Oct 24, 2021 · 1 comment

Comments

@max-privato
Copy link
Contributor

max-privato commented Oct 24, 2021

To use serial communication is very useful to be able to send and receive data from the same COM port.
Unfortunately, this seems impossible with the current version of Modelica_DeviceDrivers, since the SW tries to open the same port twice.

See for example the following model (change txt into mo before using):
RXTXissue.txt

This comes from the choice to have separate serialPortSend and serialPortReceive, which both open (or try to open) their ports.
Maybe one should add a serialPortSendReceive with two connectors one to send, the other to receive?

@bernhard-thiele
Copy link
Collaborator

Yes, or a similar approach as is used for some other devices there where is an inner config component which opens the device and the other read/write blocks can use it as outer.

I agree that it would be a nice feature. However, I'm not very knowledgeable regarding serial port programming, particularly on the Windows side. So I guess it would take me quite some time to get things running for both platforms. If somebody would provide a solid Windows implementation I'd be fine with trying for Linux :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants