I'm writing a C++ application (for Windows 7) and I need to send some data through the serial port for an Arduino. I found some code snippets googling, but most of the code it's outdated. Which libraries should I use and where can I found a detailed explanation with examples? Thanks for the help
-
1Show your workaround/code first.Pirate X– Pirate X2016-07-19 17:55:09 +00:00Commented Jul 19, 2016 at 17:55
-
Welcome to Stack Overflow! Unfortunately, this question, as it is currently posed, will likely be closed as off topic. I recommend reading How to Ask for tips on how to improve the question and bring it on topic.user4581301– user45813012016-07-19 18:07:06 +00:00Commented Jul 19, 2016 at 18:07
-
@code0 I searched on the official board/forum first, but most of the code is for Linux OSsciamp-dev– sciamp-dev2016-07-20 19:16:49 +00:00Commented Jul 20, 2016 at 19:16
Add a comment
|
1 Answer
Libserial: https://github.com/crayzeewulf/libserial/
It is an excellent library for serial port communications with C++. You'll find some easy to use examples in the examples folder on the git repo.
However, if the task gets too complicated I would recommend using Arduino's libraries ie. SoftwareSerial to make your task easier.