Kodi Community Forum

Full Version: run xbmc on 2nd monitor with 2nd audio output using 1 click
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

My setup: Windows 7, xbmc frodo, hdmi connecting the pc to the AVR. that means i have a monitor and a tv, and 2 sound outputs - 1 through the nvidia onboard sound (hdmi), 1 analog to the pc speakers.
When i'm working on the pc i use my monitor and my pc speakers.
When i go to the living room what i usually do is:
1. change to video output to extend/projector only (Win+P)
2. change the sound output (I have an AutoHotKeys executable that does this using a configurable keyboard key)
3. start xbmc (when in extend display mode, i need to move xbmc to the tv)

What i want to achieve is a 1 click app that does all these 3 actions.
That way i could go to my living room, start the receiver and the tv, and press a keyboard key using unified remote from my android device / run an android app that does all these 3 actions.

Anyone got a suggestion how to accomplish this?
I was thinking autohotkeys but i'm not sure it's capable of doing this...

Thanks!
you should be able to setup some kind of profile with your video card settings and put shortcuts somewhere to toggle. i do this, beit i have an ati card so i dont know what kind or where in the nvidia software you would need to enable this. the profile should allow you to switch monitor setup/settings and should be able to start software. otherwise you could create a batch file to open xbmc and run this profile shortcut for monitor config. if you want to control it from an android or something, you can use eventghost to capture the command which could be a ping of sorts and run the shortcut for you.

if you only use xbmc on the hdmi output, you can set xbmc to only use that device for audio, and that should take care of having to switch (#2),
Thanks!

I've been looking for something like eventghost but didn't know if such a thing exists...

Here's what i've done:
1. created a macro called "xbmc all"
2. attached it an event from my android using this application: https://play.google.com/store/apps/detai...Z2hvc3QiXQ..
3. under this macro added 3 actions:
a. send keystrokes F11 (my autohotkeys app responds to F11 as sound output toggle)
b. start application - "C:\Windows\System32\DisplaySwitch.exe", and under command line options i've entered "/internal" which tells windows to change display to my tv.
c. wait 2 seconds then start xbmc.

now, using only 1 click from my android home screen (this eventghost android application supports desktop shortcuts to events) my sound device switches to hdmi, my video output switches to my tv and xbmc starts!!!

since i've also created a similar macro which restores all configuration back to pc, I still haven't figured out how to kill xbmc using eventghost, but it's no biggie.

I have a feeling this eventghost application can do much more sophisticated things, but i've only installed it 30 minutes ago.

Thanks again!
if you want to kill xbmc using eventghost you can do this

Start Application -
Code:
C:\Windows\System32\taskkill.exe

Command Line Options
PHP Code:
/im "xbmc.exe" 
or if you want to force it close
PHP Code:
//im "xbmc.exe" 

Hope this helps.
Thanks, did it and it works great!