Fixed preview streaming (forgot to connect)
This commit is contained in:
parent
4f0f595aa0
commit
3006672e43
3 changed files with 24 additions and 3 deletions
|
|
@ -46,6 +46,12 @@ func main() {
|
|||
|
||||
bufio.NewReader(os.Stdin).ReadBytes('\n')
|
||||
},
|
||||
PreRun: func(cmd *cobra.Command, args []string) {
|
||||
camera = connectAndLogin(net.ParseIP(args[0]), int(port), username, password, verbose)
|
||||
},
|
||||
PostRun: func(cmd *cobra.Command, args []string) {
|
||||
camera.Disconnect()
|
||||
},
|
||||
}
|
||||
|
||||
rootCmd.PersistentFlags().Int16VarP(&port, "port", "P", 6666, "Specify an alternative camera port to connect to")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue