This repository allows users to synchronise compatible devices to a Prismatik powered PC backlight!
The following devices can be used with this addon:
Firstly, a working Prismatik installation is required.
A Prismatik addon is installed by copying a folder to ~/Prismatik/Plugins
.
Prismatik will run the addon by reading the .ini
file with the same
as the directory. e.g. a folder called Razer-Addon
with a
file Razer-Addon.ini
.
In this repository there are several .ini
files because this repository can
be used with several different devices. This addon can control multiple devices
by being installed several times.
Therefore to install this addon, copy this repository to the plugins folder, then rename the folder to match the device name. This can be done in two ways:
If you have Git installed, open the aforementioned directory using the command line, then run one of the following commands:
git clone <url> Razer-Addon
git clone <url> Lifx-Addon
git clone <url> OpenRGB-Addon
git clone <url> Milight-Addon
If you do not have Git installed, install this addon by doing the following:
- Download this repository as a
.zip
file, - Extract it to
~/Prismatik/Plugins
- Rename the folder to match the device to use
- For Razer: Razer-Addon
- For Lifx: Lifx-Addon
- For OpenRGB: OpenRGB-Addon
- For Milight: Milight-Addon
Python is used to run the addon, and
needs to be installed. It also needs accessible in the system path
(typing python
in the command prompt must open it).
Once python is installed, navigate to the addon directory. Open the command prompt and type the following:
python -m pip install -r requirements.txt
This will install dependencies for the project.
In Prismatik, in the 'Expert' section, select "Enable Server."
This repository contains .ico
files for turning this addon off and on via
the system tray.
- Off icon: https://www.iconfinder.com/icons/2205230/botton_left_off_on_icon
- On icon: https://www.iconfinder.com/icons/2205232/botton_off_on_right_icon
In this directory there are several .json
files that can be edited to to
configure this addon. They are as follows:
This addon works by taking the average of each individual LED in the backlight. Editing PrismatikConfig allows for controlling which LEDS are considered.
- LedStart is the index of the first LED to consider (counting begins from 0).
- LedEnd is the index of the last LED to consider. This is useful in cases where the device is situated in a place near an edge, for instance if your smart light is on the left of the monitor.
- If LedStart and LedEnd are both
none
, then all LEDs are considered. - If only LedStart is
none
then all leds untilLedEnd
are considered. - If only LedEnd is
none
then all leds fromLedStart
are considered.
How many times per second to update the lights.
Higher values are more expensive in regards to: computation and network usage (if this is an online device).
However, lower values can lead to the devices looking different than the PC backlight.
If an icon should be added to the tray that allows turning the device on and off.
Instead of sending data to devices x amount of times per second, only send a new color if it has significantly changed.
Prior to sending the HSV value to the device, the saturation is multiplied by this value. This means that devices will have stronger colours and less likely to be white. This is great for some devices (such as RGB mousemats).
Prior to sending the HSV value to the device, the value is multiplied by this value. This allows for the brightness to be made stronger or weaker.
Prior to sending the HSV value to the device, if the saturation percentage is lower than this value, then the decide is made pure white.
After calculating the brightness to send to the device, if the brightness to send is lower than this percentage of the maximum value (0.1 is 10%), the device will turn off.
After calculating the brightness to send to the device, brightness to send is
higher than this percentage of the maximum value (0.2 is 20%), and the device
is off, the device will turn back on. Having this value higher than
ValueMin_Off
avoids flickering if the brightness hovers around that value,
it's also more cinematic as the lights will only turn back on following the
darker scene having completed.
There are 3 parameters.
- The IP address of the Milight hub.
- The port to use (8899 is default).
- The zone number to use.
There are two parameters, which is the IP address and Mac Address of the lightbulb. If these are the empty string, the addon will attempt to automatically find the LIFX bulb. If not, this allows for selecting which light to control with the addon.
Including the IP Address and Mac Address is more reliable.
There is only one parameter, device_ids
which is an array of integers. These
are the ids of the devices this addon controls (the first device listed in
OpenRGB is 0).