Announcement

Collapse
No announcement yet.

In-LineLinc 2475S2 Control Script

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    In-LineLinc 2475S2 Control Script

    Here is a Insteon_ExtDevSupport script for controlling the In-LineLinc w/ sense 2475S2 module when connected to a motion security light. One of the features of the module is that the sense can be turned on and off with a FastOn or FastOff command. There was no way to send these commands (since I don't have an ISY), so I wrote this script.

    Either rename your original Insteon_ExtDevSupport.vb to Insteon_ExtDevSupport_EZ.vb and use my Insteon_ExtDevSupport.vb file to call all of your scripts, or add a line to call this script.
    hs.RunEx("Insteon_ExtDevSupport_2475S2.vb", "RegisterDevices",parm)

    First add your device to HomeSeer and use the Program Device for HomeSeer button. Then delete the device and edit the script with your device addresses, locations, and names. Restart HomeSeer to add the devices.

    The script will add 3 devices for each motion light:
    Device 1 shows the status of the light and along with the on and off button adds buttons for Always On and Always Off. This allows you to lock the light on for parties, etc, or disable it when the wind is high.
    Device 2 is for Motion Sensed. It uses the group command sent by the device to tell that it was turned on from the motion detector and not from HS or another device. This can be used for a motion trigger.
    Device 3 is for Motion Enabled. It shows whether the sense lead is active and the motion detector is enabled.

    A poll event can be set up by editing the option in the script. There appears to be a bug in the firmware for the 2475S2. When a light status request is sent, it does not answer correctly, so that feature is disabled in the poll for now. The poll will only query the sense status and update the Motion Enabled device accordingly. This is most useful when HS is first started and is called by the script.
    Attached Files

    #2
    It's not a device firmware bug

    I realized that I left the gdebug = true in the original script I posted which causes extra junk in your log file. If you are using the script, you can just set gdebug = false.

    I also checked into the device communication a bit more. The polling problem does not appear to be a bug with the device. The Insteon plug-in v 1.2.3.4 does not recognize the ACK to a light status command from a 2475S2 as an ACK, so it keeps resending the message until it times out.

    The details:
    1/5/2010 8:36:23 PM - Transmitting message on behalf of external device support script...
    1/5/2010 8:36:23 PM - Sending command 02 62 13 27 A2 01 19 00 to PLM, (Expecting 0 bytes extra back) Pre-Payload ACK:False, NAK is ok:False
    1/5/2010 8:36:23 PM - Waiting for ACK on behalf of external device support script...
    1/5/2010 8:36:23 PM - Wait: Waiting for Insteon raw message: 0* 13 27 A2 05 EB E4 ** 19
    1/5/2010 8:36:23 PM - PLM_ProcessInBuffer received STX 0x50 (Raw Insteon Rec):01 13 27 A2 05 EB E4 21 00 00 - Event: New msg for PLC , Src[13.27.A2] Dst[05.EB.E4] {Ack/Dir} Cmd:Unknown 00 Ex: 00
    1/5/2010 8:36:23 PM - ProcessRawReceiveForExternalDevices sending 01 13 27 A2 05 EB E4 21 00 00 to Insteon_ExtDevSupport_2475S2.vb:ILLRcv...
    1/5/2010 8:36:23 PM - CheckRawMessageMatch: 01 13 27 A2 05 EB E4 21 00 00 against key 0* 13 27 A2 05 EB E4 ** 19
    1/5/2010 8:36:27 PM - Wait: Did not see the message in time.
    1/5/2010 8:36:27 PM - **Did not receive a response from the external destination device for try #11

    It's likely that if Mr Sandler has time to work on this, he will just add the device type 0214 and we won't need this script. It works fine without the poll option anyway.

    Comment


      #3
      Twinch,
      looks like a pretty simple device. can you explain how fast on/off affects the device?

      if i add the basics for this device you will be able to remotely turn it on and off and link it to other devices.

      what else do you need to be able to do?
      Mark

      HS3 Pro 4.2.19.5
      Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
      Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
      Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

      Comment


        #4
        Originally posted by mnsandler View Post
        Twinch,
        looks like a pretty simple device. can you explain how fast on/off affects the device?

        if i add the basics for this device you will be able to remotely turn it on and off and link it to other devices.

        what else do you need to be able to do?
        The device has a trigger input that allows it to react to the motion sensor and turn on the flood light. Fast On turns on the flood light and also disables the trigger input until the next standard on/off command. This essentially locks the lights with no reaction to motion. Fast Off would lock the lights off.

        If we only had the basics it would be great. Other features would be nice when writing scripts. Some way to know if your sense lead is active or not would be good. The insteon special triggers would allow events based on "motion sensed" if we trigger on "Transmits and on command". That shouldn't take any extra programming on your part.

        Comment


          #5
          Twinch,
          post your email addr to my personal page and i will send you a test build to try
          Mark

          HS3 Pro 4.2.19.5
          Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
          Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
          Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

          Comment

          Working...
          X