No announcement yet.

Insteon ISY Lighting and the Elk M1 [SCRIPT]

This is a sticky topic.
  • Filter
  • Time
  • Show
Clear All
new posts

  • Insteon ISY Lighting and the Elk M1 [SCRIPT]

    I use the Insteon ISY and the Elk M1 to control my lighting. I find it easier to use the ISY software to manage the device names and locations by following a simply naming format. I use a 4 character code for the location followed by a dash followed by the device name. As an example, the master bedroom overhead light is named "BdrM-Overhead" in the ISY.

    Getting the lighting data into HomeSeer using the Elk M1 HSPI is a multiple step process.
    • Export the lighting to an XML file using the Insteon ISY software.
    • Import the Insteon lighting data into the Elk M1 using the Elk RP software.
    • Confirm the number of devices you have defined in the Elk M1 matches UltraM1G > Options > Defined Elk M1G Configuration > Lighting
    • From HomeSeer, refresh the Elk M1 configuration from UltraM1G > Status > Reload Data. The reload may take up to 5 minutes on a slow HomeSeer PC.
    • Use the script below to programmatically update the location based on the imported device names.

    Sub Main(ByVal parm As Object)
      Dim IFACE_NAME As String = "UltraM1G"
      Dim Locations As New System.Collections.Hashtable
      Locations.Add("Bsmt", "Basement")
      Locations.Add("BdmK", "Bedroom [One]")
      Locations.Add("BdmR", "Bedroom [Two]")
      Locations.Add("BdmM", "Bedroom [Master]")
      Locations.Add("Brdg", "Bridge")
      Locations.Add("Den", "Den")
      Locations.Add("DnRm", "Dining Room")
      Locations.Add("FmRm", "Family Room")
      Locations.Add("Entr", "Front Entrance")
      Locations.Add("Garage", "Garage")
      Locations.Add("Hall", "Hall")
      Locations.Add("Ktch", "Kitchen")
      Locations.Add("Outs", "Outside")
        ' Run though all the HomeSeer devices
        Dim DevEnum As Object = hs.GetDeviceEnumerator
        If Not DevEnum Is Nothing Then
          Do While Not DevEnum.Finished
            Dim objDevice As Object = DevEnum.GetNext
            If Not objDevice Is Nothing Then
              If objDevice.interface = IFACE_NAME And objDevice.dev_type_string = "Elk M1 Lighting" Then
                Dim strDeviceName As String = objDevice.Name
                For Each strKey As String In Locations.Keys
                  If strDeviceName.Contains(strKey & "-") Then
                    objDevice.location = Locations(strKey)
                    objDevice.location2 = "Elk M1 Ligthing"
                    Exit For
                  End If
              End If
            End If
        End If
      Catch pEx As Exception
        ' Process program exception
      End Try
    End Sub
    I hope someone finds this information helpful.

    Plug-ins: UltraMon, UltraM1G, UltraCID, Ultra1Wire, UltraLog, UltraWeatherBug, UltraPioneerAVR, UltraGCIR

  • #2
    Yes, I find this useful. Thank you.

    Any updates to this since the last post? Any advice outside of what is documented here?
    HomeSeer 2, HomeSeer 3, Allonis myServer, Amazon Alexa Dots, ELK M1G, ISY 994i, HomeKit, BlueIris, and 6 "4k" Cameras using NVR, and integration between all of these systems. Home Automation since 1980.