Skip to content

Instantly share code, notes, and snippets.

@ochilab
Created February 21, 2015 08:29
C#にてシリアルポートからの通信を受信する。
static void Main(string[] args){
SerialPort sPort = new SerialPort("COM3");
sPort.BaudRate = 9600;
sPort.Open();
while (true){
string myData = sPort.ReadLine();
Console.WriteLine(myData);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment