Controlling VDR with Asterisk PABX

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I feed my VDR picture throughout the house via a modulator, but wanted to be 
able to alter the channels while in other rooms.
The web interface (vdradmin) works well with a wireless tablet but it is not 
practical to carry around all the time.
The solution was to use my PABX (Asterisk), which runs on the VDR server.
Now I can pick up any phone and dial extension 837 (vdr). The PABX gives a 
beep and I then use the keys on the phone to navigate. By pressing 0 on the 
phone that takes me into number mode and after 2 seconds the system reverts 
back to navigation mode.
If anyone else is using Asterisk, then this may be a handy dial string 
(which I wrote) to include in extensions_custom.conf.


exten => 837,1,Answer()
exten => 837,n(start),Read(APCODE,beep,1)
exten => 837,n,GotoIf($[${APCODE} = 0]?vdr-numb,1:vdr-navi,1)

exten => vdr-numb,1,Read(APCODE,number,1,,,2)
exten => vdr-numb,n,GotoIf($[${APCODE} < 0]:?837,start)
exten => vdr-numb,n,System(/usr/local/bin/svdrpsend.pl HITK "${APCODE}")
exten => vdr-numb,n,Goto(vdr-numb,1)

exten => vdr-navi,1,Set(APCODE=${IF($[${APCODE} = 1]?Green:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 2]?Up:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 3]?Yellow:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 4]?Left:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 5]?Ok:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 6]?Right:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 7]?Menu:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 8]?Down:${APCODE})})
exten => vdr-navi,n,Set(APCODE=${IF($[${APCODE} = 9]?Back:${APCODE})})
exten => vdr-navi,n,System(/usr/local/bin/svdrpsend.pl HITK "${APCODE}")
exten => vdr-navi,n,Goto(837,start)

Now I can use my cordless phones (connected to a PAP2 box) to control the 
VDR completely.

Hope that helps someone :-)


_______________________________________________
vdr mailing list
vdr@xxxxxxxxxxx
http://www.linuxtv.org/cgi-bin/mailman/listinfo/vdr

[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux