Config display_rooms Question

View: New views
5 Messages — Rating Filter:   Alert me  

Config display_rooms Question

by Andy M. :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


  Another question about the mh.ini parameters display_rooms and display_apps:

  I have multiple displays in one room (ie. a SqueezeBox and a MythTV frontend) and sometimes want all displays to display the same message. So I assumed I can use the display_rooms parameter for this? Or does the display_rooms parameter actually only define individual devices, and not all the devices in one room?

  Currently I am grouping displays via apps. Everything works beautifully at the moment. I am just enquiring if I had missed the method for grouping displays in one room together before linking them to applications. That is, in the setup below I would change so that "kitchen" meant the Slim Device and MythTV devices together?

  display_rooms = lounge  => schema=osd.basic address=slimdev-slimserv.Lounge  device=xpl,
                  kitchen => schema=osd.basic address=slimdev-slimserv.Kitchen device=xpl,
                  kitchen_myth => device=mythosd

  display_apps = alert   => display_rooms=lounge|kitchen duration=58,
                 caution => display_rooms=lounge|kitchen duration=30,
                 temp    => display_rooms=lounge|kitchen duration=30,
                 info    => display_rooms=lounge|kitchen duration=10

  If the answer is no, then I don't see it as a problem. I just want to use the feature if it exists......

  ALSO, what is the function of display_groups?

Andy.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
________________________________________________________
To unsubscribe from this list, go to: http://sourceforge.net/mail/?group_id=1365


Re: Config display_rooms Question

by Gregg Liming :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Andy M. wrote:
>
>   Another question about the mh.ini parameters display_rooms and
> display_apps:
>
>   I have multiple displays in one room (ie. a SqueezeBox and a MythTV
> frontend) and sometimes want all displays to display the same message.
> So I assumed I can use the display_rooms parameter for this?

No--you want to use display_groups for this.  Yes, I know--it's
confusing.  Essentially, display_groups contains the definitions of
groups of devices--which might be mapped to a room.  And, display_rooms
contains definitions of devices.

> Or does the
> display_rooms parameter actually only define individual devices, and not
> all the devices in one room?

That is correct.

>   Currently I am grouping displays via apps. Everything works
> beautifully at the moment. I am just enquiring if I had missed the
> method for grouping displays in one room together before linking them to
> applications. That is, in the setup below I would change so that
> "kitchen" meant the Slim Device and MythTV devices together?
>
>   display_rooms = lounge  => schema=osd.basic
> address=slimdev-slimserv.Lounge  device=xpl,
>                   kitchen => schema=osd.basic
> address=slimdev-slimserv.Kitchen device=xpl,
>                   kitchen_myth => device=mythosd
>
>   display_apps = alert   => display_rooms=lounge|kitchen duration=58,
>                  caution => display_rooms=lounge|kitchen duration=30,
>                  temp    => display_rooms=lounge|kitchen duration=30,
>                  info    => display_rooms=lounge|kitchen duration=10
>
>   If the answer is no, then I don't see it as a problem. I just want to
> use the feature if it exists......
>
>   ALSO, what is the function of display_groups?

display_groups= kitchen => kitchen_squeezebox kitchen_myth, lounge =>
loung_squeezebox

I'm not personally using display_groups at the moment and don't recall
just how tested the above syntax is.  So, shout if you encounter problems.

Gregg


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
________________________________________________________
To unsubscribe from this list, go to: http://sourceforge.net/mail/?group_id=1365


Re: Config display_rooms Question

by Andy M. :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



Gregg Liming wrote:
display_groups= kitchen => kitchen_squeezebox kitchen_myth, lounge => 
loung_squeezebox

I'm not personally using display_groups at the moment and don't recall 
just how tested the above syntax is.  So, shout if you encounter problems.

  
  Time to "shout" about display_groups!

  I have been looking at display_groups and could not get them to work, as per Gregg's example above.

  Looking through the code, I don't think they ever would have worked as intended. I searched the MH code distribution, the Wiki and Google for examples of people using display_groups and have found none. Gregg's example syntax makes the most sense for usage of the parameter, so I propose we modify mh to work as such with one small change. I suggest we use a delimiter other than space. This will conform with the "room" delimiter used in the parameter display_rooms.

  An example of the format would be:

display_groups = lounge=>lounge_slim|lounge_myth, kitchen=>kitchen_slim|kitchen_myth


  The changes required are:

Index: mh
===================================================================
--- mh  (revision 1477)
+++ mh  (working copy)
@@ -6132,8 +6132,8 @@
     for my $room (split(/[,;|]/,$parms{display_rooms})) {
        if (exists($display_groups{$room})) {
           # then expand the group
-           my %groups = &parse_func_parms($display_groups{$room});
-           for my $group_room (keys %groups) {
+           my @groups = split(/[,;|]/, $display_groups{$room});
+           for my $group_room (@groups) {
              if (!(exists($targets{$group_room}))) { # prevent duplicates on expansion
                 my %room_parms = &parse_func_parms($display_rooms{$group_room});
                 %{$targets{$group_room}} =%room_parms;


  If nobody objects, I will make the change in SVN.

Andy.



-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
________________________________________________________
To unsubscribe from this list, go to: http://sourceforge.net/mail/?group_id=1365


Re: Config display_rooms Question

by Gregg Liming :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Andy M. wrote:

> Gregg Liming wrote:
>> display_groups= kitchen => kitchen_squeezebox kitchen_myth, lounge =>
>> loung_squeezebox
>>
>> I'm not personally using display_groups at the moment and don't recall
>> just how tested the above syntax is.  So, shout if you encounter problems.
>>
>>  
>   Time to "shout" about display_groups!
>
>   I have been looking at display_groups and could not get them to work,
> as per Gregg's example above.

I'm not surprised.  I had wondered about that as well.  Likely, the
addition had just not been tested.

>   Looking through the code, I don't think they ever would have worked as
> intended. I searched the MH code distribution, the Wiki and Google for
> examples of people using display_groups and have found none. Gregg's
> example syntax makes the most sense for usage of the parameter, so I
> propose we modify mh to work as such with one small change. I suggest we
> use a delimiter other than space. This will conform with the "room"
> delimiter used in the parameter display_rooms.
>
>   An example of the format would be:
>
> display_groups = lounge=>lounge_slim|lounge_myth,
> kitchen=>kitchen_slim|kitchen_myth

Looks good to me.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
________________________________________________________
To unsubscribe from this list, go to: http://sourceforge.net/mail/?group_id=1365


Re: Config display_rooms Question

by Andy M. :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



Gregg Liming wrote:
Andy M. wrote:
  
Gregg Liming wrote:
    
display_groups= kitchen => kitchen_squeezebox kitchen_myth, lounge => 
loung_squeezebox

I'm not personally using display_groups at the moment and don't recall 
just how tested the above syntax is.  So, shout if you encounter problems.

  
      
  Time to "shout" about display_groups!

  I have been looking at display_groups and could not get them to work, 
as per Gregg's example above.
    

I'm not surprised.  I had wondered about that as well.  Likely, the 
addition had just not been tested.

  
  Looking through the code, I don't think they ever would have worked as 
intended. I searched the MH code distribution, the Wiki and Google for 
examples of people using display_groups and have found none. Gregg's 
example syntax makes the most sense for usage of the parameter, so I 
propose we modify mh to work as such with one small change. I suggest we 
use a delimiter other than space. This will conform with the "room" 
delimiter used in the parameter display_rooms.

  An example of the format would be:

display_groups = lounge=>lounge_slim|lounge_myth, 
kitchen=>kitchen_slim|kitchen_myth
    

Looks good to me.
  
   Done.

Andy.

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
________________________________________________________
To unsubscribe from this list, go to: http://sourceforge.net/mail/?group_id=1365