diff --git a/config/hyperion.config.json b/config/hyperion.config.json index 3ed2b855..23786138 100644 --- a/config/hyperion.config.json +++ b/config/hyperion.config.json @@ -22,8 +22,10 @@ /// Color manipulation configuration used to tune the output colors to specific surroundings. /// The configuration contains a list of color-transforms. Each transform contains the /// following fields: - /// * 'id' : The unique identifier of the color transformation (eg 'device_1') /// * 'leds' : The indices (or index ranges) of the leds to which this color transform applies - /// (eg '0-5, 9, 11, 12-17'). The indices are zero based. /// * 'hsv' : The manipulation in the Hue-Saturation-Value color domain with the following + /// * 'id' : The unique identifier of the color transformation (eg 'device_1') + /// * 'leds' : The indices (or index ranges) of the leds to which this color transform applies + /// (eg '0-5, 9, 11, 12-17'). The indices are zero based. + /// * 'hsv' : The manipulation in the Hue-Saturation-Value color domain with the following /// tuning parameters: /// - 'saturationGain' The gain adjustement of the saturation /// - 'valueGain' The gain adjustement of the value @@ -47,7 +49,7 @@ [ { "id" : "default", - "leds" : "0-49", + "leds" : "*", "hsv" : { "saturationGain" : 1.0000, @@ -382,7 +384,8 @@ "frequency_Hz" : 10.0 }, - /// The configuration of the XBMC connection used to enable and disable the frame-grabber. Contains the following fields: + /// The configuration of the XBMC connection used to enable and disable the frame-grabber. + /// Contains the following fields: /// * xbmcAddress : The IP address of the XBMC-host /// * xbmcTcpPort : The TCP-port of the XBMC-server /// * grabVideo : Flag indicating that the frame-grabber is on(true) during video playback diff --git a/deploy/hyperion.tar.gz b/deploy/hyperion.tar.gz new file mode 100644 index 00000000..12dfa7e5 Binary files /dev/null and b/deploy/hyperion.tar.gz differ diff --git a/deploy/hyperion.tar.gz.REMOVED.git-id b/deploy/hyperion.tar.gz.REMOVED.git-id deleted file mode 100644 index bf091ef6..00000000 --- a/deploy/hyperion.tar.gz.REMOVED.git-id +++ /dev/null @@ -1 +0,0 @@ -e7d6f548d20e8a1dd817e4200fbedff8f7b042f9 \ No newline at end of file diff --git a/effects/strobe.json b/effects/strobe.json new file mode 100644 index 00000000..1af14afc --- /dev/null +++ b/effects/strobe.json @@ -0,0 +1,8 @@ +{ + "name" : "Stroboscope", + "script" : "strobe.py", + "args" : + { + "frequency" : 10.0 + } +} diff --git a/effects/strobe.py b/effects/strobe.py new file mode 100644 index 00000000..c35cbab6 --- /dev/null +++ b/effects/strobe.py @@ -0,0 +1,23 @@ +import hyperion +import time +import colorsys + +# Get the rotation time +frequency = float(hyperion.args.get('frequency', 10.0)) + +# Check parameters +frequency = min(100.0, frequency) + +# Compute the strobe interval +sleepTime = 1.0 / frequency + +# Initialize the led data +blackLedsData = bytearray(hyperion.ledCount * ( 0, 0, 0)) +whiteLedsData = bytearray(hyperion.ledCount * (255,255,255)) + +# Start the write data loop +while not hyperion.abort(): + hyperion.setColor(blackLedsData) + time.sleep(sleepTime) + hyperion.setColor(whiteLedsData) + time.sleep(sleepTime)