Windows Media Center

I recently found an add in for Media Center that I have been using to send message boxes to Media Center based on triggers from Vera.

The add in can be found here http://vmccontroller.codeplex.com/

an example of code I use for when motion is detected at the front door is luup.inet.wget(“http://xxx.xxx.x.xxx:40510/msgbox%20"Motion"%20"Detected%20Outside"%205”)

The add in can do a lot more, like start playing playlists and send rich messages like captures from webcams to Media Center and extenders.

did this work with MCE7?

Will you explain more?
Actually this is exactly what I am looking for, controlling the Windows Media Center via my Vera 2…Not controlling at least playing a specific song when some1 moves for example.
I have a vera 2 connected to a network which has a PC with windows 7 ultimate installed

I really need this

Thank you

@therealabdo, I believe you would need to do a few things:

  1. Install the add in on your Windows 7 PC.

  2. Figure out the index of the song you want to play (see http://vmccontroller.codeplex.com/wikipage?title=Commands&referringTitle=Home for commands). You would want to use one of the listing commands such as:“list-artists-songs”. You would want to do this from a computer.

  3. Play the song using an http command called from a scene on Vera: luup.inet.wget("http://<mc_comp_ip>:40510/play-audio-song<song_index>")

Thank you radarengineer

here is what i have done:

1- installed the add in (just download it and then install it, it is installed as .dll files, that’s all…anything else needed to be done?like adding it to the media center?)
2- the index of my song is: C:\Users\DigitalNet\Desktop\MUSIC\Euphoria 025 2010_06_11 - DJ Exortius.mp3
3- i have created a secene adding this luup: luup.inet.wget(“http://192.168.114.1:40510/play-audio C:\Users\DigitalNet\Desktop\MUSIC\Euphoria 025 2010_06_11 - DJ Exortius.mp3”)
4- i have opened the Media Center in the 192.168.114.1 PC, but unfortunately nothing happened.
Will you please tell me where i did something wrong?

@therealabdo, not sure if you got this working or not, but there is an alternate method that you can also use here:

http://forum.micasaverde.com/index.php/topic,9205.msg62848.html#msg62848

MCE controller has an editable list of things that it can do or launch with a keyword (apart from the basic MCE control), and if you couple that on Vera with a luup based scene, its very flexible and easy to use to do exactly what you want.

Below is an example of one I also created that dials up a VPN on my PC, which in turn uses “vpn” as keyword to launch a batch file, which in turn dials a VPN via rasdial. It then goes on to launch BBC iplayer and google chrome ,it then inputs a URL for me also and launches the site:

local socket = require("socket") host = "10.0.0.2" c = assert(socket.connect(host, 5150)) c:send("vpn\r") luup.sleep(5000) c:send("iplayer\r") luup.sleep(1000) c:send("chrome\r") luup.sleep(1000) c:send("chars:bbc.co.uk/iplayer\r") luup.sleep(1000) c:send("enter\r") c:close()

does this work on win 7 x64 mediacenter and ui5 ?

Just tested it on a Win 7 64bit PC, and despite having to install .net4 (must have already been on my 32 bit PC), it worked fine!

cool :slight_smile: thnx for testing it

Hi

Just trying this out as I already have VMCController installed on my HTPC’s.

I created a new Test Scene in VeraLite clicked the LUUP tab and put in this code

luup.inet.wget("http://mcx03:40510/msgbox%20%22Motion%22%20%22Detected%20Back%20Garden%22%205")

However when I run the scene I get no popup in MCE.

If I run this line in Chrome browser the popup works in MCE OK

http://mcx03:40510/msgbox%20"Motion"%20"Detected%20Back%20Garden"%205

What have I done wrong?

Thanks

EDIT: Tried with the IP address of the HTPC instead of the host name and that doesnt work from Vera Scene either

EDIT: Doh I’m an idiot lol, didnt click on the Save Lua button at the bottom, its working now.

Sorry to revive a semi-old thread, but my whole home video/DVD system is based on Windows Media Center extenders. The documentation for the plug-in mentions that you’re able to send message box pop-ups to MCE and extenders via the msgbox command.

CW-Kid, it looks like you are sending the command in the previous post to an extender. Do you send the command to the IP (or DNS name) of the extender or the HTPC on the specified port (based on the extender’s username)?

I’d love to be able to send notifications to my extenders when the my Kwikset deadbolts are unlocked.

Thanks,
Sean

I am only sending msgbox messages to my main MCE PC in the living room. Not tried sending them to an extender, my kids have a Linksys DMA 2100 in their bedroom so might be able to test it. I would think you need to look at the instructions for VMCController on how to send the msgbox to an extender rather than to the main MCE PC.

I just checked a scene that sends a message to VMCController on my MCE PC on motion detection via a Z-wave PIR motion sensor. I used this code:

luup.inet.wget("http://192.168.0.6:40510/msgbox%20%22Motion%22%20%22Detected%20Front%20Garden%22%205")

I guess its the next port number for the extender ? Try using Port :40511 for the first extender :40512 for the second extender. I imagine its trial and error to work out which extender is using what port number.

I also have the other TCP Controller installed as well called Kindel MCE Controller, also just noticed that the Kindel MCEController has a new version 1.5.2 that was released 5 days ago, change log is here.

Based on the VMC code site, it looks like you can send messages to individual extenders based on the port number. I assume the port number corresponds to the extender’s account user name. For example, my media center’s host name is “Media-Center-PC” and the user accounts that get created, correspond to the host name such as “Mcx6-MEDIA-CENTER-PC”.

Beta 2 adds an http server on 40510 (40511, etc for extenders) access via the web http://youserver:40510

Based on that, I’d think for that extender, I’d have to send the command to port 40516. (Although, I do have extenders that go past 10, such as “Mcx11-MEDIA-CENTER-P”, so I’d hope that it would extend to port 40521.)

From the VMC controller code list, it looks like I’d just need to send the below code to my specified extenders.

msgbox "caption" "message" <timeout seconds>

I’ll try to use your code to test it initially, for example for Mcx6, I’ll use:

luup.inet.wget("http://192.168.0.110:40516/msgbox%20%22Motion%22%20%22Detected%20Front%20Garden%22%205")

My Vera should be arriving today, so I’ll install the VMC controller software and test it out. I’m completely new to lua/luup coding, so it may take me a bit to get it up and running.

-Sean

I don’t think the port numbers relate to the extenders user account name. I think its just what ever order the extenders got added to the MCE PC in?
Port :40511 for the first extender :40512 for the second extender and so on. I imagine its trial and error to work out which extender is using what port number.

You can just put the http:// string in to the address bar of Internet Explorer and click Go to test sending the msgbox to your MCE PC / extenders. You don’t need to wait for your Vera to arrive. Obviously install VMCController first and have MCE open on the target MCE PC / extender.

Being a Windows Media Center user, you might be interested in my recent blog post about integrating mControl MCML add-in with Vera, can be found here. This post is handy as well control Vera from PC command line for use with Logitech Harmony remotes etc.

Also if you want a much cheaper option than mControl for having a UI in Media Center for controlling Vera Z-wave devices have a look at Martin’s PowerControllerMCE add-in here.

I think this add-in is free software but please make a donation if you use it!

Obviously having control over your Vera Z-wave devices from within Media Center is nothing to do with sending msgbox messages but if you have Media Center on every TV in the house you might want to consider integrating Media Center with Vera ;D

The extenders do get their name based on the order they’re added to the PC.

That would be quite inconvenient if the port number was based on the order that they connect, as you’d never be able to reliably target an individual extener, but I could definitely see the port being determined by the something like the session ID of the user account. If it does work that way, I’d just have to broadcast the message to all of the ports from :40511-40521. I would like to avoid spamming extenders that aren’t in my bedroom or the main TV, but I’d live with it if I had to.

I’ve been following your posts on TDL (it’s what got me to finally pull the trigger on Vera.) I’ve been an mControl user for years now, but they’re latest version has been quite buggy for me: no https support, iPhone/iPad app issues, general reliability of Z-Wave, slow silverlight web gui, no scene controller support, the list goes on… The MCE interface is the one thing that actually works quite well, so keeping the service running for the TV GUI is on my short list of items.

After years of dealing with HDCP handshake and resolution issues between my HTPC, AVR, and TV, I gave up on running an actual PC connected to my TV. I just run the actual MCE headless in my basement (pic attached). Because of that, I wouldn’t have a way to use the command line interface via my Harmony as I don’t think the extenders forward the IR commands to the host PC (but I could be wrong).

-Sean

Very interesting. Time to see if I can connect my HTPC via HDMI to my Tamaha HT receiver as well as via VGA directly to my TV. That way I can swap to the HTPC with one button and access my HA. Thank you!

[quote=“cw-kid, post:16, topic:168535”]Also if you want a much cheaper option than mControl for having a UI in Media Center for controlling Vera Z-wave devices have a look at Martin’s PowerControllerMCE add-in here.

I think this add-in is free software but please make a donation if you use it!

Obviously having control over your Vera Z-wave devices from within Media Center is nothing to do with sending msgbox messages but if you have Media Center on every TV in the house you might want to consider integrating Media Center with Vera ;D[/quote]

Nice looking rack! Yes you can only use the command line trick on the MCE PC’s not the extenders.

Yeah HDMI handshaking issues and black screens of death can drive one insane. I’ve had my fair share of those issues. Those Gefen HDMI detective boxes are meant to sort it out.

I’ve only just upgraded from mControl V2.1 to V3. I read about HTTPS not being supported. I’ve not really used their iOS app much, I prefer either Vera Mobile or eControl Lite on my iPod Touch. The main app I use for Vera is the excellent Authomation on our Android Samsung Galaxy Tab2.

You will not regret changing your primary Z-wave controller from mControl to Vera I can tell you! You then just need to reconfigure mControl to use the Vera Luup Driver and not use the Z-wave Controller driver and reconfigure each of your Z-wave devices in mControl to use the Luup Driver.

Vera is more stable all round as the primary controller, although I didn’t have that many issues with mControl v2.1 and the Aeon Labs Z-stick once the driver got updated for the Z-stick to stop my WHS blue screening.

[quote=“BOFH, post:18, topic:168535”]Very interesting. Time to see if I can connect my HTPC via HDMI to my Tamaha HT receiver as well as via VGA directly to my TV. That way I can swap to the HTPC with one button and access my HA. Thank you!

[quote=“cw-kid, post:16, topic:168535”]Also if you want a much cheaper option than mControl for having a UI in Media Center for controlling Vera Z-wave devices have a look at Martin’s PowerControllerMCE add-in here.

I think this add-in is free software but please make a donation if you use it!

Obviously having control over your Vera Z-wave devices from within Media Center is nothing to do with sending msgbox messages but if you have Media Center on every TV in the house you might want to consider integrating Media Center with Vera ;D[/quote][/quote]

Why would you connect a HTPC to an AVR via HDMI and VGA to the TV ? You normally just use HDMI out of PC to AVR and AVR to TV via HDMI.