forked from bjonica/mochad
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add --raw-data option from Marc Merlin
Programs such as MisterHouse can decode the raw RF data. The raw RF data can also be used to estimate the RF signal strength and noise by counting the number of invalid receptions (bad size, bad check byte, bad parity).
- Loading branch information
mmauka
committed
Jul 4, 2011
1 parent
710aa34
commit d6ac747
Showing
11 changed files
with
88 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/bin/bash | ||
|
||
# By marc_soft@merlins.org. | ||
|
||
# This script is designed to get mochad raw data to a fifo. | ||
# This is used as an input source for misterhouse, | ||
# See misterhouse/lib/X10_CMxx.pm for more details. | ||
|
||
# For this script to be useful linux with udev, you'll want | ||
# to edit /etc/udev/rules.d/91-usb-x10-controllers.rules | ||
# and make sure this script is run instead of the mochad binary. | ||
|
||
FIFO=/var/run/CM19a | ||
|
||
# Kill left over daemon just in case. | ||
killall mochad 2>/dev/null | ||
|
||
/bin/rm $FIFO 2>/dev/null | ||
mkfifo $FIFO | ||
|
||
# mochad forks off. | ||
/usr/local/bin/mochad --raw-data | ||
|
||
( while : | ||
do | ||
nc localhost 1099 > $FIFO | ||
# This will restart nc as long as the mochad daemon is running. | ||
pgrep -f /usr/local/bin/mochad > /dev/null || break | ||
done ) & |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters