• Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login
TRIGGERcmd
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Register
  • Login

ahcmd.exe problem

General Discussion
3
28
3.9k
Loading More Posts
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • N
    newstuffoldstuff
    last edited by Apr 23, 2022, 10:42 PM

    This isn't a Triggercmd problem, but I'm hoping you'll indulge me because I see there are a number of ahcmd users here and I'm having a problem with it. Specifically, it works for a while after I reboot the Windows 10 server I'm running it on. Then it stops working. The only way I've found to get it to work again is to reboot the computer. I've looked for any unusual tasks, but haven't found any. I've tried running it in various compatibility modes. Nothing.

    Instead of flashing the DOS window quickly and finishing, the DOS window comes up, stays up and hangs on the ahcmd command. I can ctrl-C out of there, but same thing time after time until a reboot.

    Without a fix for this, my hope of voice control for my old x10 stuff is fading. When it works, it's great, including with Triggercmd.

    If anyone has any suggestions, I'd appreciate hearing them.

    R N 2 Replies Last reply Apr 23, 2022, 11:37 PM Reply Quote 0
    • R
      Russ @newstuffoldstuff
      last edited by Apr 23, 2022, 11:37 PM

      @newstuffoldstuff, I don't know. I don't use ahcmd much. What is the full command you're running?

      Is it something like this?

      start C:\\autohotkeyscripts\\media.ahk mute
      

      Or like this?

      "C:\Program Files\AutoHotkey\AutoHotkey.exe" "C:\autohotkeyscripts\yourscript.ahk"
      

      I took those from this article btw.

      If you're doing one of those, you could try the other.

      Russell VanderMey

      N 2 Replies Last reply Apr 23, 2022, 11:53 PM Reply Quote 0
      • N
        newstuffoldstuff @Russ
        last edited by Apr 23, 2022, 11:53 PM

        @russ Here's the contents of one of my .bat files. When it works, it works well. Just doesn't work for more than one day, sometimes less.

        cd "C:\Program Files (x86)\Common Files\X10\Common"
        ahcmd.exe sendrf "A8 On"

        1 Reply Last reply Reply Quote 0
        • N
          newstuffoldstuff @Russ
          last edited by Apr 23, 2022, 11:59 PM

          @russ I'm probably missing something, but I'm not sure how using Sendkeys would change the situation. It's clearly an issue with ahcmd.exe. If there's an alternative to using that for programmatically controlling the x10 firecracker device, that would be helpful. Based on my research, ahcmd.exe is known to be buggy, and of course, it's old.

          R T 2 Replies Last reply Apr 24, 2022, 1:47 AM Reply Quote 0
          • R
            Russ @newstuffoldstuff
            last edited by Russ Apr 24, 2022, 12:08 PM Apr 24, 2022, 1:47 AM

            @newstuffoldstuff, sorry, I confused ahcmd.exe with autohotkey.

            You could try prefixing ahcmd.exe with start. I don't have much confidence in that but it's something I'd try.

            Edit: I read here that ahcmd exe is known to lock up. https://forums.x10.com/index.php?topic=30994.0

            I wonder if that's what you're running into. If so I wonder why. I'll do some googling.

            Russell VanderMey

            N 1 Reply Last reply Apr 24, 2022, 6:33 PM Reply Quote 0
            • T
              tuicemen @newstuffoldstuff
              last edited by tuicemen Apr 24, 2022, 3:09 PM Apr 24, 2022, 3:08 PM

              @newstuffoldstuff, the AHCMD.exe was first introduced with the AHPSDK then included with ActiveHome Pro when it was updated to work with all X10 computer models. It was never designed to be a consistantly used software but a testing tool. Unfortunately many used it to create third party X10 software instead of using the dll file included in the SDK.
              Windows 10 also created issues with it due to the security features introduce for programs located in the Program Files folder and its sub folders.
              When I controled X10 from Windows I found moving the ActiveHome Pro folder to outside of the Programs Files folder helped with unreliability. You might try that. A mother option might be to look at HomeGenie which runs on many different platforms and uses its own x10 drivers. You'd need to install the Cm17 plugin unless you had a different X10 controller which are supported with an initial install.
              I created several windows third party X10 capable softwares using the SDK dll a few accepted comandline parameter calls. I'll see if I can locate one however I never tested with the cm17 that I recall.

              N 1 Reply Last reply Apr 24, 2022, 6:30 PM Reply Quote 0
              • N
                newstuffoldstuff @tuicemen
                last edited by Apr 24, 2022, 6:30 PM

                @tuicemen Thank you! That's the kind of experience I'm looking for. Do you know of any documentation for the dll? I've been looking, but the examples I've found haven't been very transparent. Meanwhile, I'll try moving the program out of the Program Files (x86) folder.

                T 2 Replies Last reply Apr 24, 2022, 8:13 PM Reply Quote 0
                • N
                  newstuffoldstuff @Russ
                  last edited by Apr 24, 2022, 6:33 PM

                  @russ Thanks. I tried the start option before settling on my current bat file. It didn't work at all. I've read, too, that ahcmd was never meant for production, but that still wouldn't explain why it works sometimes but not others. My needs are simple, but obviously, not a lot of current work is taking place on integrations with legacy x10 products.

                  1 Reply Last reply Reply Quote 0
                  • T
                    tuicemen @newstuffoldstuff
                    last edited by Apr 24, 2022, 8:13 PM

                    @newstuffoldstuff there is some documentation in the SDK but it is limited to only a few programing languages C# , VB and VB script if I remember correctly. It also has a few sample programs along with AHCMD.
                    I used Visual Studio VB for most of my programs but did some in C#. I played a bit with java but never got it working with that.

                    N 2 Replies Last reply Apr 24, 2022, 11:07 PM Reply Quote 0
                    • T
                      tuicemen @newstuffoldstuff
                      last edited by Apr 24, 2022, 8:19 PM

                      @newstuffoldstuff you might find some info here to help if you plan to create something with the dll https://forums.x10.com/index.php?board=15.0

                      1 Reply Last reply Reply Quote 0
                      • N
                        newstuffoldstuff @tuicemen
                        last edited by newstuffoldstuff Apr 24, 2022, 11:13 PM Apr 24, 2022, 11:07 PM

                        @tuicemen I've tried creating an ActiveX object as shown in the Javascript examples, but nothing happens when I try to execute it. I suspect the object creation fails. I've read some posts saying the .dll won't work on 64-bit Windows 10, so maybe that's the problem. I read elsewhere that someone got a command to execute once, but then had to restart the x10nets service. When my system fails next (which it certainly will within the next few hours), I'll have to see whether restarting that service brings it back (rather than rebooting). In anticipation of that, I tried adding a line in my batch file to stop the service after the x10 command, but that didn't work because it requires admin privilege. Thwarted at every turn! ๐Ÿ™‚

                        1 Reply Last reply Reply Quote 0
                        • N
                          newstuffoldstuff @tuicemen
                          last edited by Apr 25, 2022, 2:47 AM

                          @tuicemen Ok...some progress. Got the Javascript to work using ahscript.dll, but only in Internet Explorer. Now the question is how to get it to execute that way in a bat file. (Is there a command line version of "Open with"?

                          1 Reply Last reply Reply Quote 0
                          • N
                            newstuffoldstuff @newstuffoldstuff
                            last edited by Apr 25, 2022, 4:31 AM

                            Thanks, guys, for your indulgence. I now have a batch file running that can run either IE or Edge and will execute the Javascript code using ahscript.dll and then kill the browser task. It seems clunky, but it works. Hopefully it will continue working for longer than the simpler ahcmd.exe. Time will tell. I appreciate your help.

                            T 1 Reply Last reply Apr 25, 2022, 11:29 AM Reply Quote 1
                            • T
                              tuicemen @newstuffoldstuff
                              last edited by Apr 25, 2022, 11:29 AM

                              @newstuffoldstuff glad to see you have it working. Now that you've figured out how to run the dll. You might want to experiment creating a simple command line program to simplify things.

                              N 3 Replies Last reply Apr 25, 2022, 2:16 PM Reply Quote 0
                              • N
                                newstuffoldstuff @tuicemen
                                last edited by Apr 25, 2022, 2:16 PM

                                @tuicemen You read my mind. Clunky is ok for starters, but itโ€™s not elegant enough.

                                1 Reply Last reply Reply Quote 0
                                • N
                                  newstuffoldstuff @tuicemen
                                  last edited by Apr 25, 2022, 2:28 PM

                                  This post is deleted!
                                  1 Reply Last reply Reply Quote 0
                                  • N
                                    newstuffoldstuff @tuicemen
                                    last edited by Apr 25, 2022, 6:19 PM

                                    @tuicemen Well, damn. Same behavior with the dll as with the exe. Works for a while and then doesn't. The x10nets service hangs and can't be restarted, disabled or anything else. Only remedy is to reboot. Now I'm stuck again.

                                    T 1 Reply Last reply Apr 25, 2022, 7:20 PM Reply Quote 0
                                    • T
                                      tuicemen @newstuffoldstuff
                                      last edited by Apr 25, 2022, 7:20 PM

                                      @newstuffoldstuff I do remember reports of x10nets hanging being reported on the x10 forum but I thought that was fixed. How did you get the files? An ActiveHome Pro install, SDK install, or third party? I'm wondering if you have an old version of the X10nets file.
                                      You might try a search on the X10 forum for the x10nets stopping.

                                      N 2 Replies Last reply Apr 25, 2022, 7:57 PM Reply Quote 0
                                      • N
                                        newstuffoldstuff @tuicemen
                                        last edited by Apr 25, 2022, 7:57 PM

                                        @tuicemen I've been doing that. I got it from the SDK installer, but it's clearly the earliest version. Have been looking for a newer one. Lots of dead links out there. I'll keep looking.

                                        T 1 Reply Last reply Apr 25, 2022, 9:44 PM Reply Quote 0
                                        • N
                                          newstuffoldstuff @tuicemen
                                          last edited by newstuffoldstuff Apr 25, 2022, 8:34 PM Apr 25, 2022, 8:27 PM

                                          @tuicemen Ok...found ActiveHome Pro installer and am now running v3.0.0.313 of x10net.dll. We'll see how that goes.

                                          1 Reply Last reply Reply Quote 0
                                          1 out of 28
                                          • First post
                                            1/28
                                            Last post