mcpigdowatch(1) FreeBSD General Commands Manual mcpigdowatch(1)

NAME

mcpigdowatchView multicast data from mcpigdod

SYNOPSIS

mcpigdowatch [-g group] [-h host] [-p port]

DESCRIPTION

mcpigdowatch is a simple client of mcpigdod(8). It allows the user to view the status of garage doors controlled by mcpigdod(8) by observing the multicast data from mcpigdod(8). The output is formatted as JSON.
The following command line options are available:
-g group
Specify the multicast group address and port (a.b.c.d:p). The default is 224.0.0.42:2121.
-h host
Specify the mcpigdod(8) host. Since the multicast data is encrypted, the mcpigdod(8) host must be contacted for the encryption key. This is done with TCP and authentication is performed with DwmAuth. If this argument is not specified, the MCPIGDODHOST environment variable (if set) will be used as the host.
-p port
Specify the TCP port on which mcpigdod(8) is listening. This is the port that will be used to authenticate and fetch the multicast encryption key.

ENVIRONMENT

MCPIGDODHOST
The default mcpigdod(8) host, used (if set) when the -h host argument is not used.

FILES

${HOME}/.dwmauth/id_rsa
The user's dwmauth private key file, created with dwmauth(1). This file should be owned by the user and have permissions 0600. It must contain the private part of a 2048-bit RSA key pair.
${HOME}/.dwmauth/id_rsa.pub
The user's dwmauth public key file, created with dwmauth(1). This file should be owned by the user and have permissions 0600. It must contain the public part of a 2048-bit RSA key pair.
${HOME}/.dwmauth/known_services
The user's dwmauth known services file. This file must contain the public key of mcpigdod(8) from the mcpigdod(8) host being queried.

EXAMPLES

Watch the multicast for the doors controlled by mcpigdod(8) on host pigdo:
% mcpigdowatch -h pigdo 
{ 
	"garageDoorStatus" : 
        { 
		"North" : 
		{ 
			"buttonState" : "Open", 
			"closedSwitchState" : "Closed", 
			"encoderState" : "Stopped", 
			"name" : "North", 
			"percentClosed" : 100, 
			"state" : "Closed" 
		}, 
		"South" : 
		{ 
			"buttonState" : "Open", 
			"closedSwitchState" : "Closed", 
			"encoderState" : "Stopped", 
			"name" : "South", 
			"percentClosed" : 100, 
			"state" : "Closed" 
		} 
	}, 
	"location" : 
	{ 
		"latitude" : 42.790700000000001, 
		"longitude" : 83.417699999999996 
	}, 
	"time" : "2017-07-06 20:07:33" 
} 
{ 
	"garageDoorStatus" : 
	{ 
		"North" : 
		{ 
			"buttonState" : "Open", 
			"closedSwitchState" : "Closed", 
			"encoderState" : "Stopped", 
			"name" : "North", 
			"percentClosed" : 100, 
			"state" : "Closed" 
		}, 
		"South" : 
		{ 
			"buttonState" : "Open", 
			"closedSwitchState" : "Closed", 
			"encoderState" : "Stopped", 
			"name" : "South", 
			"percentClosed" : 100, 
			"state" : "Closed" 
		} 
	}, 
	"location" : 
	{ 
		"latitude" : 42.790700000000001, 
		"longitude" : 83.417699999999996 
	}, 
	"time" : "2017-07-06 20:07:34" 
}

SEE ALSO

mcpigdod(8), dwmauth(1)

AUTHORS

Copyright (c) 2017 Daniel W. McRobb dwm@mcplex.net
July 6, 2017 mcplex.net