go-comtrade是一个go语言库,用来解析COMTRADE录波文件.
go get github.com/yonwoo9/go-comtrade
package main
import (
"flag"
"fmt"
"github.com/yonwoo9/go-comtrade"
)
var (
configFile = flag.String("config", "testdata/test1.cfg", "config file path")
dataFile = flag.String("data", "testdata/test1.dat", "data file path")
)
func main() {
flag.Parse()
c, err := comtrade.ParseComtrade(*configFile, *dataFile)
if err != nil {
fmt.Println(err)
return
}
fmt.Println(c.Conf)
}
go-comtrade是基于MIT license协议的开源软件.
以下这些库对go-comtrade开发设计有较大影响.