|
@@ -1,7 +1,6 @@
|
|
|
package main
|
|
|
|
|
|
import (
|
|
|
- "cicv-data-closedloop/common/config/c_log"
|
|
|
"cicv-data-closedloop/common/util"
|
|
|
"errors"
|
|
|
"fmt"
|
|
@@ -46,7 +45,7 @@ func main() {
|
|
|
time.Sleep(time.Duration(2) * time.Second)
|
|
|
snCode, err := getSnCode()
|
|
|
if err != nil {
|
|
|
- c_log.GlobalLogger.Error("获取sn码失败:", err.Error())
|
|
|
+ fmt.Println("获取sn码失败:", err.Error())
|
|
|
continue
|
|
|
}
|
|
|
fmt.Println("SN码为:", snCode)
|
|
@@ -63,7 +62,7 @@ func getSnCode() (string, error) {
|
|
|
if err != nil {
|
|
|
return "", errors.New("执行获取sn码命令" + rosparamPath + util.ToString(command) + "出错:" + util.ToString(err))
|
|
|
}
|
|
|
- c_log.GlobalLogger.Info("执行获取sn码命令", command, "成功,结果为:", snOutput)
|
|
|
+ fmt.Println("执行获取sn码命令", command, "成功,结果为:", snOutput)
|
|
|
snCode := strings.Replace(strings.Replace(snOutput, " ", "", -1), "\n", "", -1)
|
|
|
return snCode, nil
|
|
|
}
|