How do I communicate with a COM port?

0 favourites
  • 3 posts
  • Hello,

    I'm making a multiplayer game in C3 that needs to send information to a serial port. Currently, I've used the node.js plugin to run code in C# that communicates with the serial port but, it can't seem to close the port properly so that it can be opened again asynchronously.

    How can I communicate with a COM port? Essentially, I just need to be able to open the port, write to it, and then close it.

    I've seen a post for C2 from 7 years ago but I guess there is probably a new approach or method for C3?

    Thank you for your help!

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • seeing as C3 runs is a browser environment, and it is generally frowned on to let a browser directly access hardware, there is no built in way to access a COM port that I know of.

    I would have suggested node.js

    there may be some javascript library out there that you can load into C3 scripting...

    I briefly looked into it last year when trying to connect to a camera, but didn't get very far.

  • I've tried node.js but it had the same issue with closing the port. Do you remember what library you were using for connecting the camera?

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)