Skip to content

Commit

Permalink
Support industrial 'LG IP65 HMS' Highbay sensor light
Browse files Browse the repository at this point in the history
* Dimmable light
* Motion sensor
* Light sensor

http://www.lglightingus.com/ip65-high-bay.aspx
  • Loading branch information
manup committed Oct 28, 2018
1 parent 04e08ad commit b7199a5
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 3 deletions.
10 changes: 8 additions & 2 deletions bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1220,6 +1220,9 @@ void DeRestPluginPrivate::checkLightBindingsForAttributeReporting(LightNode *lig
else if (lightNode->manufacturerCode() == VENDOR_EMBER)
{
}
else if (lightNode->manufacturerCode() == VENDOR_LGE)
{
}
else if (lightNode->manufacturerCode() == VENDOR_KEEN_HOME)
{
}
Expand Down Expand Up @@ -1408,10 +1411,13 @@ bool DeRestPluginPrivate::checkSensorBindingsForAttributeReporting(Sensor *senso
// Nimbus
sensor->modelId().startsWith(QLatin1String("FLS-NB")) ||
// SmartThings
sensor->modelId().startsWith(QLatin1String("tagv4")))
sensor->modelId().startsWith(QLatin1String("tagv4")) ||
// LG
sensor->modelId() == QLatin1String("LG IP65 HMS"))
{
deviceSupported = true;
if (!sensor->node()->nodeDescriptor().receiverOnWhenIdle())
if (!sensor->node()->nodeDescriptor().receiverOnWhenIdle() ||
sensor->node()->nodeDescriptor().manufacturerCode() != VENDOR_DDEL)
{
sensor->setMgmtBindSupported(false);
}
Expand Down
9 changes: 8 additions & 1 deletion de_web_plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,7 @@ static const SupportedDevice supportedDevices[] = {
{ VENDOR_OSRAM_STACK, "TH-T_", heimanMacPrefix }, // Heiman temperature/humidity sensor
{ VENDOR_OSRAM_STACK, "SMOK_", heimanMacPrefix }, // Heiman fire sensor
{ VENDOR_OSRAM_STACK, "WATER_", heimanMacPrefix }, // Heiman water sensor
{ VENDOR_LGE, "LG IP65 HMS", emberMacPrefix },
{ VENDOR_EMBER, "SmartPlug", emberMacPrefix }, // Heiman smart plug
{ VENDOR_120B, "WarningDevice", emberMacPrefix }, // Heiman siren
{ VENDOR_LUTRON, "LZL4BWHL01", lutronMacPrefix }, // Lutron LZL-4B-WH-L01 Connected Bulb Remote
Expand Down Expand Up @@ -4054,6 +4055,10 @@ void DeRestPluginPrivate::addSensorNode(const deCONZ::Node *node, const SensorFi
{
sensorNode.setManufacturer("Heiman");
}
else if (node->nodeDescriptor().manufacturerCode() == VENDOR_LGE)
{
sensorNode.setManufacturer("LG Electronics");
}
else if (node->nodeDescriptor().manufacturerCode() == VENDOR_LUTRON)
{
sensorNode.setManufacturer("Lutron");
Expand Down Expand Up @@ -4889,7 +4894,9 @@ void DeRestPluginPrivate::updateSensorNode(const deCONZ::NodeEvent &event)
updateSensorEtag(&*i);

}
else if (i->modelId().startsWith(QLatin1String("FLS-NB")) && ia->id() == 0x0010) // occupied to unoccupied delay
else if ((i->modelId().startsWith(QLatin1String("FLS-NB")) ||
i->modelId() == QLatin1String("LG IP65 HMS"))
&& ia->id() == 0x0010) // occupied to unoccupied delay
{
if (updateType != NodeValue::UpdateInvalid)
{
Expand Down
1 change: 1 addition & 0 deletions de_web_plugin_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@
#define VENDOR_EMBER 0x1002
#define VENDOR_PHILIPS 0x100B
#define VENDOR_ATMEL 0x1014
#define VENDOR_LGE 0x102E
#define VENDOR_JENNIC 0x1037 // Used by Xiaomi, Trust
#define VENDOR_CENTRALITE 0x104E
#define VENDOR_NYCE 0x10B9
Expand Down

0 comments on commit b7199a5

Please sign in to comment.