use new serial lib

This commit is contained in:
zhiqiang feng
2020-12-29 11:00:01 +08:00
parent 38a4dbdb84
commit 2011a10464
8 changed files with 45 additions and 35 deletions
+2 -2
View File
@@ -91,8 +91,8 @@ func start() {
}
logger.Info("starting read")
}
buffer, count := utils.ReadPort()
if count > 0 {
buffer, err := utils.ReadPort()
if err == nil {
if lograw && len(buffer) > 0 {
fmt.Print(string(buffer))
}