You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implementation of port discovery through Pluggable discovery (#900)
* Upgraded arduino-cli and replaced serialutils dep
* Refined ports filter
* Silenced linter warning
* Use pointers in ports lists
* Made spList a method of SpPortList
* Renamed SpPortList in SerialPortList
* Removed unneded initialization
* Inlined discovery loop
* Made updateSerialPortList a method of SerialPortList
* Made enumerationLock private
* Made portsLock (ex Mu) field private
* Inlined function call
* Made findPortByName a method of serialhub and moved near it
* Inlined call to 'write' and removed the function
* Removed unused ManufacutrerId and DeviceClass, renamed some fields
* Simplified enumerateSerialPorts function
* Removed redundant loggin of serial port list
* Removed seriallist.go and inlined function calls
* Make the singleton 'tools' a pointer
* Implemented serial-discovery
* Remove no more used 'Busy' field
* Fixed error message
Copy file name to clipboardExpand all lines: main.go
+31-33
Original file line number
Diff line number
Diff line change
@@ -26,6 +26,7 @@ import (
26
26
"io"
27
27
"os"
28
28
"os/exec"
29
+
"regexp"
29
30
"runtime"
30
31
"runtime/debug"
31
32
"strconv"
@@ -69,24 +70,27 @@ var (
69
70
70
71
// iniflags
71
72
var (
72
-
address=iniConf.String("address", "127.0.0.1", "The address where to listen. Defaults to localhost")
73
-
appName=iniConf.String("appName", "", "")
74
-
gcType=iniConf.String("gc", "std", "Type of garbage collection. std = Normal garbage collection allowing system to decide (this has been known to cause a stop the world in the middle of a CNC job which can cause lost responses from the CNC controller and thus stalled jobs. use max instead to solve.), off = let memory grow unbounded (you have to send in the gc command manually to garbage collect or you will run out of RAM eventually), max = Force garbage collection on each recv or send on a serial port (this minimizes stop the world events and thus lost serial responses, but increases CPU usage)")
75
-
hostname=iniConf.String("hostname", "unknown-hostname", "Override the hostname we get from the OS")
76
-
httpProxy=iniConf.String("httpProxy", "", "Proxy server for HTTP requests")
77
-
httpsProxy=iniConf.String("httpsProxy", "", "Proxy server for HTTPS requests")
78
-
indexURL=iniConf.String("indexURL", "https://downloads.arduino.cc/packages/package_index.json", "The address from where to download the index json containing the location of upload tools")
autostartMacOS=iniConf.Bool("autostartMacOS", true, "the Arduino Create Agent is able to start automatically after login on macOS (launchd agent)")
73
+
address=iniConf.String("address", "127.0.0.1", "The address where to listen. Defaults to localhost")
74
+
appName=iniConf.String("appName", "", "")
75
+
gcType=iniConf.String("gc", "std", "Type of garbage collection. std = Normal garbage collection allowing system to decide (this has been known to cause a stop the world in the middle of a CNC job which can cause lost responses from the CNC controller and thus stalled jobs. use max instead to solve.), off = let memory grow unbounded (you have to send in the gc command manually to garbage collect or you will run out of RAM eventually), max = Force garbage collection on each recv or send on a serial port (this minimizes stop the world events and thus lost serial responses, but increases CPU usage)")
76
+
hostname=iniConf.String("hostname", "unknown-hostname", "Override the hostname we get from the OS")
77
+
httpProxy=iniConf.String("httpProxy", "", "Proxy server for HTTP requests")
78
+
httpsProxy=iniConf.String("httpsProxy", "", "Proxy server for HTTPS requests")
79
+
indexURL=iniConf.String("indexURL", "https://downloads.arduino.cc/packages/package_index.json", "The address from where to download the index json containing the location of upload tools")
0 commit comments