I grumbled when I had to convert from HS2 to HS3, wondering if it was really worth all the effort. It didn't take long to realize it was well worth the effort. HS3 has a number of improvements in the Events making it more powerful, and more logical to follow. The devices are simpler and more consistent. Devices have many improvements in capabilities for display where you can link icons to specific values, etc. One of the nicest improvements is that device values update on screen automatically and instantly as they change without having to continually hit the refresh button. I'm sure that once you get into it you will love HS3 and see the value of converting just like I did.
Announcement
Collapse
No announcement yet.
Migrating functions from SG to HS
Collapse
X
-
Originally posted by ggrumbles View PostThank you so much! Yes, I understand completely.
I dont even know where to get the native command set for SG anymore. I actually have never used the ASCII-OUT function with SG.
I am wondering, however, what HS3 gives you over HS2. It seems interface is slicker and updated, but what else do you guys find that HS3 does or does/better than HS2?Attached FilesMike____________________________________________________________ __________________
HS3 Pro Edition 3.0.0.548, NUC i3
HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti
Comment
-
I successfully re-implemented my Commstar (Stargate) communication using direct control through the COM port. I wanted to throw a question to the group and get some ideas.
I am sending the commands via events in HS3 and reading any commands that come from the CommStar through the EventHandler script.
I have noticed that HS3 won't stack the commands to the COM port - it seems to throw them all at once. So if I have several events triggering then I need to make sure they don't send the commands to the Commstar at the same time as the Commstar seems to ignore any overlapping commands. Is this correct?
I started to employ a response from the Commstar "ACK:LIGHTSON" for example - to let HS3 know that the command was received and executed.
However, I am trying to code this to make sense. Obviously if I don't get an ACK back, EventHandler doesn't know this. So I need to create a situation where HS3 knows it sent the command, and tell it to wait a certain amount of time to receive an ACK before it tries the command again.
I have thought of some cumbersome ways to do this but I thought I would throw it out there to get some ideas?
Comment
-
Originally posted by simonmason View PostI have noticed that HS3 won't stack the commands to the COM port - it seems to throw them all at once. So if I have several events triggering then I need to make sure they don't send the commands to the Commstar at the same time as the Commstar seems to ignore any overlapping commands. Is this correct?Mike____________________________________________________________ __________________
HS3 Pro Edition 3.0.0.548, NUC i3
HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti
Comment
-
For each of my commstar lights (x10) I have created a virtual device in HS3. Then when I turn on/off the virtual device I have an event that sends the command to commstar to turn it on or off. If I turn all of the lights on in a room at the same time, then several events will trigger at the same time and Commstar is not getting them all.
This is why I was thinking of putting some code in to check to see if the ACK came back and then going from there.
Comment
-
Okay, now I think I understand.
I'm pretty sure both RCS and HS build in methods to deal with the lag in executing X10 commands, so that they are queued properly and executed in order. You are bypassing all of that, though, so I'm guessing the Commstar cannot handle the serial inputs while it's dealing with the X10 outputs. To compensate you are now going to have to replicate the queuing functionality yourself.
Probably not the answer you are looking for, but I think it would be much easier to use the HS3 X10 plug-in. If you use the TI-103 or XTB-232 as the interface, I think you will find that the performance is quite good.
Alternatively, If you are committed to using the Commstar as the X10 interface, I'd use one command to tell it to turn on multiple lights in a room, then have the Commstar translate that into the needed X10 commands.Mike____________________________________________________________ __________________
HS3 Pro Edition 3.0.0.548, NUC i3
HW: Stargate | NX8e | CAV6.6 | Squeezebox | PCS | WGL 800RF | RFXCOM | Vantage Pro | Green-Eye | Edgeport/8 | Way2Call | Ecobee3 | EtherRain | Ubiquiti
Comment
-
I agree the native X-10 plugin is the way to go. I did start there - using an old Cm11a. That didn't work well. I decided to revert back to the Commstar because it is hooked to an XTB and it works very well.
I have moved the majority of my lights to zwave. The only reason I have any X-10 devices left is because some of the old wiring in the house has no neutral.
It's not a big deal. I don't have enough lights left to support purchasing a new XTB 232 although that would be the best way to go if I had a bigger setup.
Comment
-
I just noticed this thread today.
I've been a user of Michael's approach for a long time with HS2 and now with HS3.
I don't know if this might help or not but I added a scheme for SG to ack back to HS when HS sends ASCII to SG to control relays and flags. I only use a few SG flags, but I use all the relays. The scheme is to simply to send a command back to HS after SG receives a command to change the state of a relay or a flag. HS will continue to send the command up to 10 times until it receives a reply. If it doesn't I get a text msg and HS speaks "Stargate ASCII error".
I also trigger SG to send the status of all critical DI, AI inputs and relay states to HS when either SG or HS re-starts as well as every few minutes.
I use flag heartbeats between HS and SG and have SG reboot the HS computers if HS doesn't keep up.
I am using two SG Com ports connected to HS at the present time. One for HS2 and the other for HS3 while I transition from HS2 to HS3 which I have been doing for the past year or two. So far, it has all been very reliable.
Comment
-
Here is a piece of sendSG_ASCII.vb
Select Case cmdSubj
Case "RY" ' Relay
hs.SetDeviceValueByRef(208, 0, True) ' ASCII Failure set to OFF
theDevice = cmdSubj & cmdOption
hs.SendToComPort(8, theDevice & "||" & cmdReq)
'hs.WriteLog("RY Send", theDevice & "||" & cmdReq)
'hs.WriteLog("RY Ack=", Convert.ToString(hs.DeviceValue(207)))
For counter = 1 To 10 ' get ack from SG from getSG_ASCII script - try 10 times
hs.WaitSecs(1)
'If hs.DeviceValueEx(207) = 0 And hs.IsScriptRunning("getSG_ASCII_3.vb") = False Then ' 207 Ack is set by getSG_ASCII
If hs.DeviceValue(207) = 0 Then
hs.SendToComPort(8, theDevice & "||" & cmdReq) ' send again if no ack
hs.WaitSecs(1)
' hs.WriteLog("Counter=", Convert.ToString(counter))
Else
Exit For ' exit the For if ack was received from SG
End If
Next
If counter = 11 Then ' if failed to get ack from SG
hs.SetDeviceValueByRef(208, 100, True) ' set the failure device to ON
hs.SetDeviceLastChange(208, Now)
If hs.DeviceValueEx(55) = 100 Then ' if watchdog on send text message
hs.RunScriptFunc("text2Speech_3.vb", "Main", "2|002|80", True, False)
hs.RunScriptFunc("sendTextMessage_3.vb", "Main", "1|2", True, False)
hs.WriteLog("SG Failure", "RY")
End If
Else ' if recd the ack from SG
If cmdReq = "ON" Then ' if ack was recd set device to actual status
hs.SetDeviceValue("W" & cmdOption, 100)
End If
If cmdReq = "OFF" Then
hs.SetDeviceValue("W" & cmdOption, 0)
End If
hs.SetDeviceValueByRef(207, 0, True) ' clear ack device
End If
Here is part of getSG_ASCII
Case "RY" ' SG Relay Command Acknowledgement from sendSG_ASCII
theDevice = "W" & strOption
hs.SetDeviceValueByRef(207, 100, True)
'hs.WriteLog("getSG_ASCII", theDevice & strMessage)
theStatus = strMessage
If theStatus = "ON" Then
hs.SetDeviceValue(theDevice, 100)
End If
If theStatus = "OFF" Then
hs.SetDeviceValue(theDevice, 0)
End If
Not real fancy but it works.
Comment
-
I'm just trying to set this up, but get the following error message when the Startup.vb script runs....12/24/2021 19:47:32 HomeSeer Error In OpenComPort, port already in use12/24/2021 19:47:32 HomeSeer System Control Panel Immediate Script: &hs.OpenComPortTerm(8, "9600,N,8,1", 1, "GetSG_ASCII.vb", "Main", "$")
I have checked - and I currently have the Stargate Com 2 attached to Com 8 on the HS4 PC. How do you open the port if it's already in use? I am assuming that there is constant traffic on the Stargate Com 2, hence reasing this as in use.
I have tried starting HS4 before starting Stargate, but receive the same error.
Any advice on this gratefully received!
Mark
Comment
Comment