| Author |  | 
      
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          I waited until the time felt right to do the upgrade. I
           | Posted: April 04 2015 at 18:14 | IP Logged |   |  
           | 
 |  have been hanging out on 2.1.4 and today I installed a
 new KPL 2334-222 and I knew that to install it, I would
 need to upgrade PH. So away I went. I renamed the old PH
 directory, uninstalled the old versions using the windows
 control panel uninstall program feature. I installed the
 new 2.1.5c version, copied over the old pwrhome.ini and
 db files and rand the phupg utility (no errors).
 Powerhome 2.1.5c starts up but as soon as I start
 interacting with it, it freezes up and it crashes. I have
 tried rebooting a few times, but still I get crashes.
 
 Oh well, I figured. I'll just go back to 2.1.4. Nope. Now
 I get an error about a missing "PBVM115.dll".
 
 Help me, Obi-Wan Davenobi! You're my only help! Where do
 I start with troubleshooting this?
 
 System info
 Windows Vista
 Service Pack 2
 x64
 
 This is a standalone PH box and doesn't do anything else
 other than run PH.
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 04 2015 at 19:07 | IP Logged |   |  
           | 
 |  
 Uninstalling the old versions is probably what is
 keeping you from going back to 2.1.4. You should be
 able to do a full install of 2.1.4 (renaming any
 existing directories...you never want to install into
 an existing dir) and then copy your backed up (or
 original) 2.1.4 db and ini and you should be good to
 go.
 
 However, it would be best to stay on 2.1.5c if you
 can. Do you get any error messages or does PowerHome
 just "hang"? What directory is 2.1.5c installed in?
 Give me a little info about the freeze and crash.
 Also, you may want to try reinstalling 2.1.5c in case
 the install was corrupted (just rename your existing
 2.1.5c directory...don't uninstall anything).
 
 Let me know,
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          The only message is the standard windows "%APPNAME% is
           | Posted: April 04 2015 at 19:30 | IP Logged |   |  
           | 
 |  not responding" and windows can check for a solution
 (like that EVER helped!), with the options to check for a
 solution, close the program or to wait for the program to
 respond.
 
 I wonder if it could be a plugin or controller problem. I
 remember I had at least one bad controller (or maybe it
 was a plugin) but 2.1.4 was happy to just ignore it. It's
 a plugin for my Denon receiver. I could just delete it,
 but I can't interact with PH at all. It crashes so
 quickly.
 
 I do have PH installed in the standard c:\powerhome
 folder.
 
 Is there a way to selective see and choose what
 controller and plugins are loaded?
 
 Oh wow, just now, while I was typing this, I was watching
 the PH screen. I had that dialog up regard the app crash.
 Well, it just went away, so it seems to be responding.
 For now.
 
 I went to help-about and I see four controllers loaded
 Elk
 USB_UIRT1
 USB_UIRT2 (I have two of them)
 PLM
 
 That all looks good
 
 Under plugins, I do have one invalid plugin
 PowerHome Plugin ID: DENON
 Plugin failed during initialization.
 
 So, let's see if I can open the Insteon Explorer...
 Check! It worked.
 
 OK, I think I need to look into that plugin. How do I get
 rid of that and test some more?
 
 Warning: Standby for questions regarding the KPL if I get
 this working :)
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          Well, that didn't last long. It froze up again. I'll let it
           | Posted: April 04 2015 at 19:36 | IP Logged |   |  
           | 
 |  sit on the frozen screen (it is an all white screen and the
 title bar says "not responding")
 
 And of course, while I was just typing this, it went away
 and started responding again. So it was frozen for about a
 minute or two.
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          Sorry for all of the rapid-fire responses. But I have
           | Posted: April 04 2015 at 19:47 | IP Logged |   |  
           | 
 |  more information.
 
 If I just let it sit and don't touch it, periodically
 (live every couple of minutes) I will get a popup that
 says "Lost communications with M1XEP on Elk M1 Controller
 ELK. Attempting to reconnect. And it is supposed to count
 down 3, 2, 1 and then close by itself, right? Well, it is
 stuck on 3. And I can't click it or anything else. But if
 I wait long enough, it will eventually go away, but I
 still can't do anything with it. Not Responding. But if I
 wait long enough, eventually it will start working again,
 like nothing was wrong.
 
 I know the ethernet controller is fine. It was working
 this morning on 2.1.4, and the Elk is doing fine too. So
 it's something else.
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          By the way, every time I post something in the forum here,
           | Posted: April 04 2015 at 19:49 | IP Logged |   |  
           | 
 |  I get an error
 
 error '8004020f'
 /forum/functions/functions_send_mail.asp, line 151
 
 And when I press the back button, sure enough the post did
 indeed post. But something is wrong. This has happened
 every time I posted today.
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 04 2015 at 19:57 | IP Logged |   |  
           | 
 |  
 Ive been getting the send mail error message as well.
 Not every time but at least half of my posts get the
 message. Something that I will have to look into with
 the forum software.
 
 With PowerHome shutdown, open the pwrhome.ini file and
 go to the [System] section. Change the LoadCtlrs and
 LoadPlugins parms both to NO. Save and launch
 PowerHome. Lets see if it hangs with both controllers
 and plugins not installed. If it works, shutdown and
 try changing to just loading controllers. Lets see if
 we can narrow it down to controllers or plugins (or
 other) being the problem.
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          OK, we are starting to get somewhere. Setting both to
           | Posted: April 04 2015 at 20:36 | IP Logged |   |  
           | 
 |  "NO" allowed it to work for 20 minutes with no problem.
 No surprise there, actually. Setting Controllers to NO
 and plugins to YES also allowed PH to work for quite a
 while with no issues. I figures out how to disable the
 one plugin that I had through PH Explorer-Setup-Plugins,
 so no surprise there either. But when I set Plugins to NO
 and Controllers to YES, I get a freeze very shortly after
 launch. Specifically, I figured out it would freeze right
 after the first zone status change. So, on the next
 launch, right after launch I would go to Help-About and I
 figured out that I could disable the Elk controller
 before any zone changes happened. And now it is running
 for about ten minutes now without a crash.
 
 But I need the elk controller working! So, what's the
 next step?
 
 By the way, thanks for the help, Dave! 9:30 on a Saturday
 night, no less!
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 04 2015 at 22:41 | IP Logged |   |  
           | 
 |  
 So it appears that the Elk M1XEP is what is causing
 the hang. I have the same controller in my setup and
 have not had a problem although I do sometimes get the
 lost communication message.
 
 I'll do a comparison between 2.1.4 and 2.1.5c and see
 what may have changed in the Elk controller so perhaps
 can pinpoint what is going on.
 
 I'll let you know what I find.
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 04 2015 at 23:21 | IP Logged |   |  
           | 
 |  
 Well after looking at the code, alot has changed. The
 version of PowerBuilder changed, the Catalyst winsock
 control version changed, and the code for the Elk M1
 controller was pretty much retooled. Im not going to
 be able to locate the issue that way.
 
 Since it "hangs" and then comes back, perhaps we can
 narrow down a little on your system. Can you have the
 PowerHome Status screen running and then watch the
 execution queue to see if the hang occurs based upon
 what is in the queue and what shows on the realtime
 log. See if we can see any patterns there.
 
 Next, if you can time it right, try going to File-
 >Debug Info and capturing the data to the clipboard
 and emailing the results to me. If possible, try to
 get captures just before and just after the hang. If
 you're able to do this, it will yield some good
 internal information.
 
 Last, are sending any commands to the Elk (controller
 commands) or doing anything else programmatically with
 the Elk? You say the hang seems to happen during a
 zone status. Can you give me more info on what is
 occuring with your system when this happens?
 
 Appreciate it.
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          I think I am getting somewhere. I think it is related to
           | Posted: April 05 2015 at 06:55 | IP Logged |   |  
           | 
 |  the ph_geturl1() formula. As I was testing, disabling
 triggers and lines in macros and whatnot, it seems that any
 time I try to execute that formula, it crashes.
 
 So, I went to test the url I am sending, and it seems that
 the website is doing fine, no issues there that I can
 identify, but I am not going to rule out a possible problem
 with the website. Strange that it was working fine on
 2.1.4, but now has problems on 2.1.5c. Really strange.
 
 What is your email address anyway?
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          By the way, is there a SQL command I can execute to get the
           | Posted: April 05 2015 at 06:57 | IP Logged |   |  
           | 
 |  macro name of any macro that has at least one formula that
 uses the ph_geturl1 command? I have a lot of macros that
 call that command. I guess I should learn how to write
 "subroutine" type macros...
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 05 2015 at 10:08 | IP Logged |   |  
           | 
 |  
 Not sure why that would cause a problem as that
 function didnt really change other than upgrading to
 the latest version of the Catalyst winsock control.
 Let me know what your testing shows though and I'll
 see what I can do. There are several options with the
 ph_geturl1 function so let me know the particular
 option you're using.
 
 Email address is my username at myx10.com.
 
 Easiest way to find where you've used a particular
 function is the "Database where used" report under the
 reports menu. Just wildcard your search like this:
 
 %ph_geturl1%
 
 For the SQL way to do it:
 
 
| Code: 
 
    
    | 
      
       | select id from macrodetail where send_keys like '%ph_geturl1%'
 |  |  |  
 Hope this helps,
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          That search report is pretty cool! I have never seen that
           | Posted: April 05 2015 at 10:53 | IP Logged |   |  
           | 
 |  before.
 I usually use it like this
 ph_geturl1("URL",1,20)
 Although, I did see one time where I used a 3,20, and I
 have no idea why. I should write more comments in my code.
 I don't even remember what those options are for. So far,
 it looks like everything is OK on my server. I don't see
 any issues. I see in my logs other users using it, and it
 seems fine when I send manual commands via my browser. I
 can try and find out if any of them are on 2.1.5c and if
 they are using the same command.
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | nick7920 Senior Member
 
  
 
 Joined: March 04 2008
 Location: United States
 Online Status: Offline
 Posts: 193
 | 
          Skip,
           | Posted: April 05 2015 at 13:03 | IP Logged |   |  
           | 
 |  
 I had problem with ph_geturl1 when I upgraded to 2.1.5 and I
 think I have posted somewhere on the forum.
 
 What I had to use instead was ph_getitcurl.
 
 mine to work with PHCA (android app) example : (url is
 https)
 
 ph_getitcurl("{PHCA_SERVER}&garage_st={GARAGE_MAIN}",20)
 
 (side note)
 Also after upgrade make sure you have all the global
 variable copied and working, I had a problem with variable
 which had data length of more than 255 character.
 
 Nick
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          OK, I will give that a shot. Thanks, Nick!
           | Posted: April 05 2015 at 16:30 | IP Logged |   |  
           | 
 |  
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          ph_getitcurl fixed it perfectly! Game on!
           | Posted: April 07 2015 at 18:18 | IP Logged |   |  
           | 
 |  
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip and Nick,
           | Posted: April 07 2015 at 22:08 | IP Logged |   |  
           | 
 |  
 Just wondering if you can try the ph_geturl1 function
 with the different option types to see if any of those
 options will work or not. Not really sure why only the
 ph_getitcurl function works and it would help me to
 pin down what is unique about it if one of the other
 options on ph_geturl1 will also work.
 
 Appreciate it.
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  | 
        | MrGibbage Super User
 
  
  
 Joined: October 23 2006
 Location: United States
 Online Status: Offline
 Posts: 513
 | 
          I just did some testing. Here's the command that I sent:
           | Posted: April 08 2015 at 08:10 | IP Logged |   |  
           | 
 |  ph_geturl1(  "{PHCA_SERVER}?username={PHCA_USER}&password={PHCA_PASS}&ala rmstate=" + ph_htmlescape("{ELK_ALARM_STATE_AREA1}"),0,20)
 And this is how it was sent after the variable substitution
 ph_geturl1(  "https://phca-web.appspot.com/send?username=skip&password=XX XXXX&alarmstate=" + ph_htmlescape("No Alarm Active"),0,20)
 
 I tried it for options
 0,20
 1,20
 2,20
 3,20
 
 Option 0 failed somewhat gracefully without locking up, but it popped up a dialog box with the following error message:
 An error occurred while processing the execution queue.  Resetting execution queue and trying again.
 *** Error Details ***
 Error Number: 39
 Object Name: uo_socketblob
 Class: uo_socketblob
 Routine Name: f_geturl
 Line: 51
 Text: Error accessing external object property remoteport at line 51 in function f_geturl of object uo_socketblob.
 
 Options 1 and 2 both locked up the system for exactly 4 minutes each with no other information.
 
 Option 3, however, was successful!
 
 Edited by MrGibbage - April 08 2015 at 08:11
 
 __________________
 Skip
 | 
       
        | Back to Top |     | 
       
       
        |  | 
        | dhoward Admin Group
 
  
  
 Joined: June 29 2001
 Location: United States
 Online Status: Offline
 Posts: 4447
 | 
          Skip,
           | Posted: April 09 2015 at 23:00 | IP Logged |   |  
           | 
 |  
 Really appreciate the testing. This info along with
 data from another user has helped me to pinpoint the
 issue with the ph_geturl1 function.
 
 Basically, any websites requiring SSL are going to
 have an issue with options 0, 1, or 2. If the website
 is non-SSL then everything should work. Option 3 does
 work for both SSL and non-SSL but will be slow for SSL
 sites. If retrieving data from an SSL site, you should
 set the timeout value to as small a value as will
 work.
 
 I'll have this fixed in the next version.
 
 Thanks,
 
 Dave.
 
 | 
       
        | Back to Top |       | 
       
       
        |  |