SageTV Community  

Go Back   SageTV Community > General Discussion > The SageTV Community
Forum Rules FAQs Community Downloads Today's Posts Search

Notices

The SageTV Community Here's the place to discuss what's worth recording, HTPC deals at retail stores, events happening outside of your home theater, and pretty much anything else you'd like. (No For-Sale posts)

Reply
 
Thread Tools Search this Thread Display Modes
  #21  
Old 05-16-2008, 11:48 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Quote:
Originally Posted by StephaneM View Post
You'll have the same exact issues with multituner plugin than you had trying to make work your USB-UIRT with both the SageTV client and SageTV service (that is having to choose an appopriate account for the service).
Why is that? Since SageClient and SageService will NOT be touching the USB-UIRT. They will only send messages to the single process that will have exclusive access to the usb-uirt. The issue I had with running sageservice and sageclient and usb-uirt is that both processes wanted access to the usb-uirt and it would not allow it.
Reply With Quote
  #22  
Old 05-16-2008, 11:54 AM
StephaneM's Avatar
StephaneM StephaneM is offline
Sage Icon
 
Join Date: Mar 2006
Location: France
Posts: 1,463
Quote:
Originally Posted by m1abrams View Post
Why is that? Since SageClient and SageService will NOT be touching the USB-UIRT. They will only send messages to the single process that will have exclusive access to the usb-uirt. The issue I had with running sageservice and sageclient and usb-uirt is that both processes wanted access to the usb-uirt and it would not allow it.
The issue with USB-UIRT is not that two processes are trying to access the device, is that two processes with different security context are acessing the device.

I don't use the Multituner Plugin but I've read that it also have issues depending on the account you use for the SageTV Service. That's why I think you'll have issues with the multituner plugin as you were having issues with the USB-UIRT. (the LM RKM tuning plugin for SageTV doesn't have issue with the account used for the SageTV service)
Reply With Quote
  #23  
Old 05-16-2008, 11:55 AM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
Once you convert over to EXEmultituner.dll the USBUIRT is no longer used by Sage at all. EventGhost handles all the incoming an outgoing IR. I know that part works as thats what I am doing now.

I have a USBUIRT and use EventGhost for transmission to other devices.

What I do not have is a cable box so i have no need for Sage to do any channel changes aside from the tuner inside my PVR500s. What I think I will do in testing is map a DVD from my changer as a channel in the guide. Then sage will use EXEmultituner.dll to request EventGhost to use the USBUIRT.
Reply With Quote
  #24  
Old 05-16-2008, 11:58 AM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
Quote:
Originally Posted by StephaneM View Post
I don't use the Multituner Plugin but I've read that it also have issues depending on the account you use for the SageTV Service. That's why I think you'll have issues with the multituner plugin as you were having issues with the USB-UIRT. (the LM RKM tuning plugin for SageTV doesn't have issue with the account used for the SageTV service)
Thats why I mentioned the -n syntax, this will bring commands to the same user as is running EventGhost regardless of which user intiated it.

So you may have to use:


[HKEY_LOCAL_MACHINE\SOFTWARE\Sage\EXETunerPlugin]
"command"="EventGhost.exe -n 127.0.0.1:1024 1234 STB-%DEVICE%.%CHANNEL%"

To bypass this, this is also why I use this method from my MVPs.
Reply With Quote
  #25  
Old 05-16-2008, 12:02 PM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
GREAT info all, I can not wait to get home and try this stuff out. May have more questions when I get in the thick of it. Probably going to start with EventGhost cause I think that has more versatility for other applications such as controlling my Denon via serial cable.

Hmmm do we do this hobby to watch TV better or do we Watch TV to justify this hobby?
Reply With Quote
  #26  
Old 05-16-2008, 03:55 PM
BobPhoenix BobPhoenix is offline
SageTVaholic
 
Join Date: Oct 2004
Posts: 3,152
Quote:
Originally Posted by m1abrams View Post
Why is that? Since SageClient and SageService will NOT be touching the USB-UIRT. They will only send messages to the single process that will have exclusive access to the usb-uirt. The issue I had with running sageservice and sageclient and usb-uirt is that both processes wanted access to the usb-uirt and it would not allow it.
I just use this app to launch the SageTV GUI with the same USERID as used by the SageTV Service and avoid the problem with Sage and the USB-UIRT. But it may not help with what you are trying to do. Just wanted to point you at a free app that I found useful and may help with the USB-UIRT being used as both a blaster and reciever.

Edit: Didn't see your post in another thread. This definitely won't help if using the same user and password doesn't work for you.

Last edited by BobPhoenix; 05-16-2008 at 04:08 PM.
Reply With Quote
  #27  
Old 05-18-2008, 05:50 PM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Ok so far things with EventGhost are working well. I can control SageTV and PowerDVD with it and switch between the 2 apps.

One final step I would like to do is have EventGhost change STB channels. I have the multituner plugin working with SageTV sending the event to EventGhost. The event looks like
Main.STB-StubDevice.25

Where 25 is the channel to change to. So I guess I need to write a little python script to handle the event? Has anyone already done a similiar type of script? If not I guess I need to read up on my python.
Reply With Quote
  #28  
Old 05-19-2008, 07:31 AM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
Take this to the EventGhost forums, you should not need any python scripting to get the rest of the way home.

My concern is your event, it looks like it my only support 1 STB I don't know where the

"Main.STB-StubDevice.25"

You want that to say something like 1, lol.

You need to make a folder under
context/globals/STB-1/

Inside you need to teach EventGhost your STB IR codes 0-9 and OK or Enter.
Reply With Quote
  #29  
Old 05-19-2008, 07:42 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Quote:
Originally Posted by CollinR View Post
Take this to the EventGhost forums, you should not need any python scripting to get the rest of the way home.

My concern is your event, it looks like it my only support 1 STB I don't know where the

"Main.STB-StubDevice.25"

You want that to say something like 1, lol.

You need to make a folder under
context/globals/STB-1/

Inside you need to teach EventGhost your STB IR codes 0-9 and OK or Enter.
Yes I need to set up multituner to use more than one device, it is possible in the reading I have done, but just wanted to get it working with one first. Stubdevice is the default device for the multituner plugin.

I did teach EventGhost my STB IR codes 0-9 and EG will send them to the tuners. I think I need to make a script for EG so that when I get the incoming event from Sage I need to parse it so that I know which device to control and then what IR codes to send.
Found this thread seems to have the solution:
http://www.eventghost.org/forum/view...channel+change
Reply With Quote
  #30  
Old 05-19-2008, 07:52 AM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
Excellent find and that was the thread I was thinking about. You will probably want to change.

Code:
# get the event
event = eg.EventString


parts = event.split(".")


value = parts[-1]


if value.isdigit():

    # iterate over every digit 
    for digit in value:

        # send an event for the digit
        eg.TriggerEvent("STB-1 SendIR" + digit)
To allow for multiple STBs.

Also you WILL need to add in your delays so you don't swamp the STB as EventGhost will fire this off way way too fast. The easiest way I can think of is put a .5 second delay at the end of each IR code macro. If thats not enough you may need to step up to a full second.


Also don't forget you can copy/paste to from EventGhost and you favorite text editor or even the forum posts. If your first delay attempt is too short just copy that folder and paste in a text editor. Then use a replace command and have it change all the delays in one shot. Then just paste it back into EventGhost. I love that part!!!

Last edited by CollinR; 05-19-2008 at 08:02 AM.
Reply With Quote
  #31  
Old 05-19-2008, 08:08 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
I am going to tweak that script a bit so that if the number is less than 3 digits that it send a "enter" IR command at the end. That will speed up channel changes a bit. Or I could just zero pad numbers to 3 digits.
Reply With Quote
  #32  
Old 05-19-2008, 11:49 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Have not tested this yet since I am at work but this is the script I think I will use. This zero pads the channel number to 3 digits so that the channel changes are a little faster (SA stb does not wait when you send 3 digits). It also supports multiple tuners, by grabbing out the %DEVICE% string.
Question do I need to "import string" in my script for EG or is that already imported? Does it even hurt to import it more than once? or is python smart enough to ignore the second import. I assume it is smart enough.

Code:
# get the event
event = eg.EventString

parts = event.split(".")

tuner = parts[-2]

channel = parts[-1]

channel.zfill(3)

if channel.isdigit():

    # iterate over every digit 
    for digit in value:

        # send an event for the digit
        eg.TriggerEvent(tuner + digit)
Reply With Quote
  #33  
Old 05-19-2008, 06:34 PM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Ok so this is what my final script looks like. Works pretty well right now. One issue that I can not solve is I have the Multituner sending an event that looks like this:
Main.STB.STBTop.212

I was hoping to use a wildcard event for the script of Main.STB.*
However that does not seem to work, it never triggers the event. Main.* works though and is what I am currently using however it triggers more than needed so I tried to write the script to exit out as fast as i can if it is not the correct event. Any ideas to improve it? Will post later on EG forum too, need to register.

Code:
# get the event
event = eg.EventString

parts = event.split(".")
if len(parts) == 4 and parts[-3] == 'STB':
    tuner = parts[-2]
    channel = parts[-1]
    print tuner
    if channel.isdigit():
        channel = channel.zfill(3)
        # iterate over every digit 
        for digit in channel:

            # send an event for the digit
            eg.TriggerEvent(tuner + '-' + digit)
Reply With Quote
  #34  
Old 05-20-2008, 07:56 PM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Ok made another tweak. Note this thread is now also used for my own reference, but figured maybe someone else can learn from it too.

I added a prefix to the TriggerEvent, this makes it so that the prefix is NOT "Main" which reduces the number of false triggers on the Main.* event.

Code:
# get the event
event = eg.EventString

parts = event.split(".")
if len(parts) == 4 and parts[-3] == 'STB':
    tuner = parts[-2]
    channel = parts[-1]
    print tuner
    if channel.isdigit():
        channel = channel.zfill(3)
        # iterate over every digit 
        for digit in channel:

            # send an event for the digit
            eg.TriggerEvent(tuner + '-' + digit,prefix="ChangeChannel")
Reply With Quote
  #35  
Old 05-20-2008, 09:28 PM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
Sweet and good idea about the "Main." that is the default for all command line inputs.

Pretty neato little app huh.
Reply With Quote
  #36  
Old 05-21-2008, 06:16 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Quote:
Originally Posted by CollinR View Post
Sweet and good idea about the "Main." that is the default for all command line inputs.

Pretty neato little app huh.
Oh I am liking this little app. The possibilities seem endless. My next step is to hook up my Denon 3805 via serial cable and config EG to control it via serial.
Reply With Quote
  #37  
Old 05-21-2008, 06:50 AM
jsonnabend jsonnabend is offline
Sage Aficionado
 
Join Date: Sep 2006
Posts: 301
I will be making the move from Girder to EG soon, and I've been reading this thread with great interest. Keep on tinkerin' and reporting back here with the results. It's appreciated.

- Jeff
Reply With Quote
  #38  
Old 05-21-2008, 07:57 AM
CollinR CollinR is offline
Sage Icon
 
Join Date: Dec 2004
Location: Tulsa, OK
Posts: 1,305
You can use EventGhost's network sender/reciever to communicate with Girder directly so no need to fully switch over unless you want to.

The developers of EventGhost were plugin builders for Girder before they went commercial. FYI

I personally think EventGhost is far easier to use and am shocked when I hear people claim they cannot figure it out. It's really quite simple and from looking at the M1's work you can see even the advanced scripting in python isn't too difficult. Not that I have a clue how to creat anything, but anyone can look at whats there and quickly figure out what it does.
Reply With Quote
  #39  
Old 05-21-2008, 08:41 AM
m1abrams's Avatar
m1abrams m1abrams is offline
Sage Aficionado
 
Join Date: Sep 2004
Posts: 445
Oh and when you are working with it, note that you can cut&paste anything. This is such a nice feature, if you paste into say notepad it will actually paste the XML data so that you can then manipulate it with things like Find&Replace, then copy that and paste it back to EG. Much better way of making the same change over and over again.
Reply With Quote
  #40  
Old 05-21-2008, 09:40 AM
jsonnabend jsonnabend is offline
Sage Aficionado
 
Join Date: Sep 2006
Posts: 301
Quote:
Originally Posted by CollinR View Post
You can use EventGhost's network sender/reciever to communicate with Girder directly so no need to fully switch over unless you want to.

The developers of EventGhost were plugin builders for Girder before they went commercial. FYI

I personally think EventGhost is far easier to use and am shocked when I hear people claim they cannot figure it out. It's really quite simple and from looking at the M1's work you can see even the advanced scripting in python isn't too difficult. Not that I have a clue how to creat anything, but anyone can look at whats there and quickly figure out what it does.
Thanks for the info. I like that EG is being actively developed (unlike Girder, which is apparently in perpetual, pay-to-test beta). I also like that it's open source, and Python programming should be an easy jump for this Delphi old-timer.

I'm not too concerned about changing over. I'll start building the configuration in EG, turning it on to test and off in favor of Girder for regular use until the EG config is done.

- Jeff
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
EventGhost for Firefly and Vista mightyt Hardware Support 19 09-06-2008 06:35 AM
Sagetv + MCE Blaster + Eventghost mlapaglia Hardware Support 0 01-13-2008 10:50 AM
How to gracefully exit sage when the spinning circle appears? btrcp2000 SageTV Software 16 11-25-2007 05:54 PM
I connected EventGhost, SageTV, Foobar2000, and my Harmony 880 remote to my HTPC scat SageTV Software 2 08-31-2007 08:42 AM
ANy way to Shut Down the PC from within Sage? kelemvor SageTV Software 23 02-11-2007 04:46 AM


All times are GMT -6. The time now is 06:28 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2023, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.