Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

What I'm trying to do is send caller ID (CID) information from a system running Asterisk+FreePBX to all (3) MythTV frontend systems on my network. I'd like the CID information to pop-up over top of whatever is going on (eg, whether it's on a menu, or playing back a recording). Eventually there may be other information as well, but for now CID would be a great start.

The libnotify-style notifications are fine (though I probably need to increase text size to make it visible). I was thinking something like Growl, though this doesn't seem to exist for Linux.

Ideally I'd just be able to do some kind of broadcast to the whole network, eg, from the FreePBX system I could run a command like:

notify --broadcast  --title "Incoming Call"  "Smith J\n613-555-1234"

And then on any mythtv frontend, it would appear somewhere on screen.


Note: there is a MythNotify plugin, which I have used in a previous iteration of my setup, but it has a severe limitation (I believe based on the way MythTV's OSD stuff works) that it can only display notifications during video playback: not while in menus. I also remember it being a pain to get displaying properly: it uses XML for messaging then XSLT to change to mythtv's XML format. If you want to display something slightly differently, you have to make a small handful of new XML files and even then getting the "callerid-from-phonebook.xml" message to actually render to the (remote) "callerid-from-phonebook-osd.xml" file for display is some kind of black art.

share|improve this question
1  
Sounds like we need an OSD client to receive messages sent using wall. –  Ryan Thompson Aug 6 '10 at 18:00

1 Answer 1

up vote 2 down vote accepted

You could do it by using the command-line notification tools.

  1. Install the package 'libnotify-bin' on all of the systems on your network, which provides a tool called 'notify-send'.
  2. Install the ssh server on all the systems on your network and make sure they are configured to allow passwordless ssh logins (see http://www.debian-administration.org/articles/152 for more information on this).
  3. Set up your notification script on your server to execute notify-send, like this:

    ssh username@system1 'notify-send "Incoming call from Smith J\n613-555-1234"'

    ssh username@system2 'notify-send "Incoming call from Smith J\n613-555-1234"'

This will cause a notification popup on the systems named 'system1' and 'system2'.

share|improve this answer
2  
I am sorry but your suggestion does not work, notify-send depends on the current session dbus, connecting via ssh will not setup the DBUS_SESSION_BUS_ADDRESS variable to the proper address. –  João Pinto Aug 6 '10 at 20:19
1  
What I did was make a shell script on each system that did export DISPLAY=:0 (necessary to interact with X from ssh), then called notify-send (with some other params). On one of the systems, I even have that script wake up the screen first (its an LCD monitor, using dpms). –  gregmac Aug 7 '10 at 20:13

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.