Your Digital Media Has Never Looked So Good

 
joergnapp
Topic Author
Posts: 4
Joined: Sat May 17, 2008 9:00 am
Contact:

A new toolset to display information (weather, rss,...)

Sat May 17, 2008 9:12 am

All,

I'm starting a script based on Tools4Roku to display information on my Soundbridge. The main difference between the existing solutions will be its extensibility: You will have "modules" you can use (or let out) to display information, so you can customize the script very easy.

A typical configuration would be like this:

my @modules = ( 
            {
              name => 'Hello World',
              module => 'helloworld',
              params => {},
            },
            {
              name => 'tagesschau.de',
              module => 'rss',
              params => {rss => 'http://www.tagesschau.de/xml/rss2'},
            },
            {
              name => 'heise.de',
              module => 'rss',
              params => {rss => 'http://www.heise.de/newsticker/heise-atom.xml'},
            },
            {
              name => 'Yahoo! weather',
              module => 'yahooweather',
              params => {location => 'GMXX4980'},
            },
            {
              name => 'check mails',
              module => 'checkmail',
              params => {server => 'pop.example.com', user => 'joedoe', pass => 'secret'},
            },
           );


The name entry is for the menu, the module name will be the Perl module used, and the (optional) params parameter will be module-specific.

Right now, I'm finishing the usual "hello world" module, which will be something like
package helloworld;
use strict;
use warnings;

use RokuUI_Nic4;

my $display;

# ---------------------------------------------------------------------
# Constructor
sub new {
   my ($class, $params) = @_;
   my $self = {};
   bless $self, $class;
};

# ---------------------------------------------------------------------
# Paint on the display
sub action {
   my $self=shift;
   $self->{'display'}->clear();
   $self->{'display'}->msg(text =>  "Hello world", duration => 10, x => 0, y => 0);
   $self->{'display'}->cmd("sketch -c exit");
}

1;



I think this sketch gives you the main idea. A module needs to have a property named display (to pass the main display object), and a method named action to do something (most likely, show something on the display, but other actions could be taken as well :)). Plus, the constructor new can accept parameters to control the behaviour of the module.

Does this makes sense?

Jörg
Last edited by joergnapp on Sun May 18, 2008 11:45 am, edited 1 time in total.
 
joergnapp
Topic Author
Posts: 4
Joined: Sat May 17, 2008 9:00 am
Contact:

Sun May 18, 2008 11:43 am

OK, the first prototype is up and running :) You can download it here. Please note that this release is useful for developers only, as it doesn't do anything useful yet.

If someone wants to contribute, please contact me.

Jörg
 
joergnapp
Topic Author
Posts: 4
Joined: Sat May 17, 2008 9:00 am
Contact:

Tue May 20, 2008 10:53 am

I set up a project on Google Code for this. For current development and releases see http://rokutools.googlecode.com.

BTW: The RSS Ticker is up and working :)
 
Goemon
Posts: 38
Joined: Sat Oct 20, 2007 6:58 am
Location: Germany
Contact:

Sun Nov 02, 2008 12:57 pm

Hello Joerg,

I like your idea, unfortunaltely U do not get much responce to your posts... wait, I will write you a PM.

Goemon
Soundbridge M1001 / uNSLUng / mt-daapd / [url=http://billiatjapan.netfirms.com/Tools4Roku] Tools4Roku
Image
[/url]
 
Burkhardi
Posts: 1943
Joined: Tue Jun 07, 2005 11:06 am
Location: Austin, Texas ...Y'all

Sun Nov 02, 2008 1:10 pm

Goemon wrote:
Hello Joerg,

I like your idea, unfortunaltely U do not get much responce to your posts... wait, I will write you a PM.

Goemon


Will Joerg's app work on a windows box, or just Linux/Unix systems?
Roku3 and Roku HD1000 [Rev B] on a Samsung HLP5674W DLP in the living room; a Roku2 and two Roku XS and a few SoundBridges.Win7; Kubuntu and XP via RT-N66U, E2000 and a switch or two. I own stock in Roku, it's just all in the form of hardware.Viva la Roku
 
Goemon
Posts: 38
Joined: Sat Oct 20, 2007 6:58 am
Location: Germany
Contact:

Sun Nov 02, 2008 1:51 pm

It will run on all systems capable of running perl. So Windows is also possible.

Goemon
Soundbridge M1001 / uNSLUng / mt-daapd / [url=http://billiatjapan.netfirms.com/Tools4Roku] Tools4Roku

Image

[/url]
 
fizze
Posts: 191
Joined: Wed May 03, 2006 5:46 am
Location: Austria
Contact:

Sun Nov 16, 2008 8:52 am

That sounds like a lovely project. Open Source certainly should be embraced. :)
Too bad I now zig about perl.

But I'll try to give this a spin and report my findings.

edit:
Well, I've installed
libxml-perl
libxml-dom-perl
libnet-telnet-perl

And when I try to start the roku.pl I get:
Global symbol "$DEBUG" requires explicit package name at ./roku.pl line 52.
BEGIN not safe after errors--compilation aborted at ./roku.pl line 66.


When I try to run the rss module I get:
Global symbol "$DEBUG" requires explicit package name at ./modules/rss.pm line 14.
Execution of ./modules/rss.pm aborted due to compilation errors.


Some kind of installation or usage pointers would be nice in your readme ;)
Soundbridge M1001
de-u/c'd NSLU2 Unslung 6.8 - mt-daapd svn-1696
 
jgoor
Posts: 20
Joined: Sun Feb 11, 2007 2:57 pm

Tue Jan 06, 2009 4:38 am

I installed Tools4Roku recently an finally my M1001 does more then just showing the time.
Great!
It also appeared to me that Tools4Roku is somewhat limited: you hit the nail on the head by making this nice piece of software expandable!

I just would show my appreciation for your work. Nice one!

Thank - you -very - much!

BTW: I have the same findings as frizze.
Any idea how to solve this?
 
Magnate
Posts: 7
Joined: Mon Oct 22, 2007 4:15 am
Location: London, UK
Contact:

Is this project dead?

Sat Jun 20, 2009 11:01 am

Nothing on the Google code page since May 2008 ... I guess tools4roku is still the only tool for rating songs with a SB?
"When I gave food to the poor, they called me a saint. When I asked why the poor were hungry, they called me a Communist."

Who is online

Users browsing this forum: No registered users and 1 guest