[chronojump-server] RFID.cs doesn't check for Arduino (faster). Should be only one /dev/ttyUSB*
- From: Xavier de Blas <xaviblas src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [chronojump-server] RFID.cs doesn't check for Arduino (faster). Should be only one /dev/ttyUSB*
- Date: Wed, 5 Jul 2017 18:52:48 +0000 (UTC)
commit 28a9883ff43c860f1aa587fe448f836da693e41e
Author: chronojump <chronojump@chronojumpserver>
Date: Wed Jul 5 20:51:07 2017 +0200
RFID.cs doesn't check for Arduino (faster). Should be only one /dev/ttyUSB*
chronojumpserver/rfid-csharp/RFID.cs | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
---
diff --git a/chronojumpserver/rfid-csharp/RFID.cs b/chronojumpserver/rfid-csharp/RFID.cs
index ad74994..073987c 100755
--- a/chronojumpserver/rfid-csharp/RFID.cs
+++ b/chronojumpserver/rfid-csharp/RFID.cs
@@ -81,12 +81,16 @@ public class RFID
string str = "";
+ /*
bool found = findRFIDPort(l);
if(! found)
return StatusEnum.NO_RFID_PORT;
+ */
+
+ //findRFIDPort() opens the port, but now is not called
+ port = new SerialPort(l[0], 9600); //for the rfid
+ port.Open();
- //don't need to open port because it's still opened
- //port.Open();
Console.WriteLine("Detection starts!");
DateTime ts_start = DateTime.Now;
while(! stop)
@@ -132,6 +136,7 @@ public class RFID
return StatusEnum.DETECTED;
}
+ /*
private bool findRFIDPort(List<string> l)
{
foreach(string p in l)
@@ -169,6 +174,7 @@ public class RFID
}
return(false);
}
+ */
private List<string> getPorts(bool debug)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]