Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - royw

Pages: [1] 2
1
Users / VOIP infrastructure questions
« on: August 12, 2008, 02:35:49 am »
Howdy,

I'm ready to take the plunge and switch the house from POTS to VOIP.  After searching the wiki and forums I still have a couple of questions.  Any pointers, advice, opinions would be appreciated.

First the house is partially wired for 1GB ethernet and has partial wireless coverage, but three rooms don't have either.  I'm not adverse to running more ethernet wire.  I currently have 5 phones (2 phones have 2 wireless headsets for a total of 7 headsets).  Where my core/hybrid is, I currently do not have a POTS drop.

The three wiring scenarios I see are:

1) What I think would be easiest, if it's doable, would be to disconnect the POTS from the external phone line, then put a ATA (IAXy S101I?) where I have both a LAN drop and a POTS drop.  That would allow the existing phones to continue to be used as is.  Then over time I could migrate to VOIP phones.

2) The next scenario is the same as #1 except would use an ATA/PCI adaptor and require adding a POTS drop near the core/hybrid.

3) The last scenario would be replacing the POTS drops with ethernet drops, then either switching to VOIP phones or ATA adaptors at each drop.

What I'd really like to know is if one or more of the above scenarios is a NO-GO before I try.

My next area of confusion is in looking at VOIP services.  If I understand correctly, all I really need is a bare bones service that provides a sip id/gateway and a phone number (and a low cost  :) ).  All of the frills like call waiting/forwarding/...  will be handled locally in the LinuxMCE core/hybrid.

Is there a larger list of known compatible VOIP services than what is listed at:  http://wiki.linuxmce.org/index.php/VOIP_Service_Providers?  Any recommendations for Texas?

Thank you,
Roy

2
Installation issues / Replaced video card, now weird problem
« on: August 09, 2008, 03:13:06 am »
Howdy,

My nVidia 7300 blew some capacitors the other day (photo http://www.flickr.com/photos/royw2/2745659538/), so replaced it with an nVidia 9800 GT.  No X on first boot, then couldn't even get AVWizard to run.  So upgraded to the latest nVidia drivers (NVIDIA-Linux-x86-173.14.12-pkg1.run) per wiki directions and had X working but the onscreen orbiter showing in a little bitty box centered on the display.  More hassles with AVWizard before I hit the winning combination of using the bottom DVI connector to my HDMI TV, followed by entering '1' on the blank screen AVWizard (no case speaker so no beeps).  UI2 without alpha blending.

Well and good.  Got Onscreen orbiter, screen saver working.  But when I use the onscreen orbiter to try to select Media, Videos nothing happens.  I can select all of the other Media sub-items (TV, Audio,...).  OK, I had one of my NFS systems off line, got it back on-line, problem still exists.  OK, try using my nokia n800 and the videos show up fine there (UI-1).  Rooting around in the logs and the only possibility I see is a comment that device 19 has not registered.

Wondering if anyone has any ideas, suggestions?

TIA,
Roy

3
Developers / Maximum # of Performer attributes?
« on: July 25, 2008, 08:54:30 pm »
Howdy,

I currently have 858 movies ripped, which have 31438 Performer (FK_AttributeType = '2') attributes (avg 37 performers/movie).  In both UI 1 & 2, Sort by Performer is only displaying from "Katie Mullins" to the end of the alphabet.

Any hints on where I can find the limit on number of performers?

Thank you,
Roy

4
Developers / Proposed flickr.pl replacement
« on: July 04, 2008, 02:30:35 am »
Howdy,

The other day I had an inkling to "tune" the types of photos that the screensaver uses.  So found the /usr/pluto/bin/flickr.pl script and took a look see.  There appears to be the capability to specify search tags, but they don't work (actually specifying a tag stops all fetching from flickr).  I then dived into the flickr API to understand enough to maybe troubleshoot flickr.pl.  I ended up writing a script that can handle fetching photos by user id/name, photoset, group, photo search (tags, text,...), and of course interestingness (what works in flickr.pl).  I then started thinking of replacing flickr.pl, so added LinuxMCE file structure and reaping.  I'm at the point of adding the database hooks and daemonizing the script and decided now is probably a good time to bounce this off of the community.

BTW, my current hypothesis on what is wrong with flickr.pl is that the flickr API has changed since the Flickr::API version 0.08 module was released in March 2006.  There is a newer version, 0.09 available that was released in Feb 2008 that might resolve the tag search problem.

To give you a better feel for what my script can do, here's it's current config file:
Code: [Select]
# This is the configuration file for /home/royw/views/flickrfetchr/flickrfetchr and is where
# you specify what images you want fetched from flickr for the LinuxMCE screensaver
#
# To take full advantage of these options, you should have an account on http://www.flickr.com
#
# For those who are familiar with ruby, the format for this file should be obvious :)
# But for the vast majority, here goes:
#
# Comments start with an '#' and extend to the end of the line
#
# We are initializing the config Hash so each line starts with "config[key]".  The keys
# are all symbols so start with a colon (":key").
#
# Each hash value is an Array so is enclosed in square brackets:
#   config[:key] = []
#
# Empty brackets are permissible
#
# Each element in the value Array is a Hash so is inclosed with curly brackets:
#  config[:key] = [{}, {}, ...]
#
# Each element in the Hash is a key/value pair which are seperated by a =>
#  config[:key] = [{:key1 => value1, :key2 => value2, ...}]
#
# Again each key is a symbol and starts with a colon
#
# String values are enclosed with single quotes while integers are not.  In this
# config file, all values are either integers or strings, even though I document
# the strings with more descriptive types like 'USER_ID' or 'PATH'.
#  config[:key] = [{:key1 => '/home/flickr', :key2 => 20, ...}]
#
# Each section includes an example at the end which starts with ## which show
# proper syntax for that section.

#****** Fetch photo definitions

#***********************************************************************
# To fetch photos from a user account using either the flickr user ID or the user name:
# config[:USERS] = [{
#                       :nsid => USER_ID OR :username => FLICKR_USER_NAME,  # required
#                       :destination => :linuxmce_flickr OR PATH,           # optional, defaults to :linuxmce_flickr
#                       :limit => INTEGER                                   # optional, defaults to @config[:limit]
#                       :extras => STRING                                   # don't use
#                       :per_page => INTEGER                                # optional, defaults to :limit
#                       :page => INTEGER                                    # optional, defaults to 1
#                   }]
##
## this example selects all pictures (up to @config[:limit]) from the user "royw2" flickr account:
config[:USERS] = [{:username => 'royw2'}]

#***********************************************************************
# you can also fetch photos from flickr groups again by either group ID or group name:
# config[:GROUPS] = [{
#                       :nsid => GROUP_ID OR :groupname => GROUP_NAME,      # required
#                       :destination => :linuxmce_flickr OR PATH,           # optional, defaults to :linuxmce_flickr
#                       :limit => INTEGER                                   # optional, defaults to @config[:limit]
#                       :tags => STRING                                     # optional, A tag to filter the pool with.
#                                                                           #   At the moment only one tag at a time is supported.
#                       :extras => STRING                                   # don't use
#                       :per_page => INTEGER                                # optional, defaults to :limit
#                       :page => INTEGER                                    # optional, defaults to 1
#                   }]
##
## this example will fetch photos from two groups: 'Deep Space Astrophotography' and 'Worlds of fancy_computer generated landscapes'.
## The group id for 'Deep Space Astrophotography' is '16194850@N00' so we will use it:
## config[:GROUPS] = [{:nsid => '16194850@N00'}, {:groupname => 'Worlds of fancy_computer generated landscapes'}]

#***********************************************************************
# config[:PHOTOSETS] = [{
#                       :nsid => USER_ID OR :username => FLICKR_USER_NAME,  # required
#                       :destination => :linuxmce_flickr OR PATH,           # optional, defaults to :linuxmce_flickr
#                       :title => STRING                                    #
#                       :limit => INTEGER                                   # optional, defaults to @config[:limit]
#                       :title => STRING                                    # optional, matches one set, default is to match all sets
#                       :extras => STRING                                   # don't use
#                   }]
##
## Say I want to keep a local copy of one of my photosets ('Our Canine Family'), but not include it in the LinuxMCE screensaver
## config[:PHOTOSETS] = [{:username => 'royw2', :title => 'Our Canine Family', :destination => '/home/royw/photos/dogs'}]

#***********************************************************************
# config[:SEARCHES] = [{
#                       :nsid => USER_ID OR :username => FLICKR_USER_NAME,  # required
#                       :destination => :linuxmce_flickr OR PATH,           # optional, defaults to :linuxmce_flickr
#                       :limit => INTEGER                                   # optional, defaults to @config[:limit]
#                       :tags => STRING                                     # optional, A comma-delimited list of tags.
#                                                                           #   Photos with one or more of the tags listed will be returned.
#                       :tag_mode => 'any' OR 'all'                         # optional, Either 'any' for an OR combination of tags,
#                                                                           #   or 'all' for an AND combination.
#                                                                           #   Defaults to 'any' if not specified.
#                       :text => STRING                                     # optional, A free text search. Photos who's title,
#                                                                           #   description or tags contain the text will be returned.
#                       :min_upload_date => STRING                          # optional, Minimum upload date. Photos with an upload
#                                                                           #   date greater than or equal to this value
#                                                                           #   will be returned. The date should be in the
#                                                                           #   form of a unix timestamp.
#                       :max_upload_date => STRING                          # optional, Maximum upload date. Photos with an upload
#                                                                           #   date less than or equal to this value will be returned.
#                                                                           #   The date should be in the form of a unix timestamp.
#                       :min_taken_date => STRING                           # optional, Minimum taken date. Photos with an taken
#                                                                           #   date greater than or equal to this value will be returned.
#                                                                           #   The date should be in the form of a mysql datetime.
#                       :max_taken_date => STRING                           # optional, Maximum taken date. Photos with an taken
#                                                                           #   date less than or equal to this value will be returned.
#                                                                           #   The date should be in the form of a mysql datetime.
#                       :license => STRING                                  # optional, The license id for photos (for possible values
#                                                                           #   see the flickr.photos.licenses.getInfo method).
#                                                                           #   Multiple licenses may be comma-separated.
#                       :extras => STRING                                   # don't use
#                       :per_page => INTEGER                                # optional, defaults to :limit
#                       :page => INTEGER                                    # optional, defaults to 1
#                   }]
##
## Now say I want to include photos of LinuxMCE systems that are on flickr and up to 20 computer case mods:
## config[:SEARCHES] = [{:text => 'LinuxMCE'},
##                       {:tags => 'computer,case,mods', :limit => 20}
##                      ]

#***********************************************************************
# config[:INTERESTING] = [{
#                       :nsid => USER_ID OR :username => FLICKR_USER_NAME,  # optional
#                       :destination => :linuxmce_flickr OR PATH,           # optional, defaults to :linuxmce_flickr
#                       :limit => INTEGER                                   # optional, defaults to @config[:limit]
#                       :date => STRING                                     # optional, a date string
#                       :daycount => INTEGER                                # optional, the number of days up to :date to look
#                                                                           # for photos.  defaults = 0 (i.e., just :date)
#                       :extras => STRING                                   # don't use
#                       :per_page => INTEGER                                # optional, defaults to :limit
#                       :page => INTEGER                                    # optional, defaults to 1
#                   }]
##
## Say I'm feeling nostalgic for the orginal photo selection in LinuxMCE:
## config[:INTERESTING] = [{:limit => 100, :daycount => 5}]

#****** Global Fetch Options
# The following are global options with the default values
# please note that the value syntax differs from the above sections.

#***********************************************************************
# The maximum number of files to attempt to download at a time
## config[:limit] = 3

#***********************************************************************
# Sometimes downloading from flickr is unreliable, so we can retry the
# operation this many times:
## config[:max_save_attempts] = 3

#***********************************************************************
# When FlickrFetcher downloads an image, it limits downloading to the largest possible image that is
# less than or equal to config[:image_max_size] and greater than or equal to config[:image_min_size].

# This is the maximum photo size to download.  If the requested photo exceeds this size in either width or height,
# then we try to find the next smaller image.  If there are no smaller images, then the image is not downloaded.
## config[:image_max_size] = {:width => 1920, :height => 1080}
# Setting either width or height to less than or equal to 0 disables the checking for a maximum size.
## config[:image_max_size] = {:width => 0, :height => -1080}

# This is the minimum photo size to download.  If the requested photo is smaller than this size in either width or
# height then the photo is not downloaded.
## config[:image_min_size] = {:width => 1024, :height => 720}
# Setting either width or height to less than or equal to 0 disables the checking for a minimum size.
## config[:image_min_size] = {:width => -1920, :height => 0}

#***********************************************************************
# config[:image_scale_to_size]  = {:width => 1920, :height => 1080}

#***********************************************************************
# config[:linuxmce_flickr] = {:max_files => 100}



Thank you,
Roy


5
Howdy,

One of the pains of testing different releases or just recovering from a botched experiment, is having to reapply all the little tweaks to your system after a (re)install.  Particularly if you don't have a separate test system.

While setting up the deploy for a rails app, it hit me that I can just use Capistrano (http://capify.org/) for remote scripting all of these little tweaks.

To use, you need to install ruby and rubygems on your workstation, then use gem to install Capistrano.  You do not have to install anything on your dcerouter.  Your workstation does need to be able to ssh to your dcerouter.

I'm going to present this example as from a kubuntu workstation.  As I normally use gentoo, there might be a few mistakes (I did run each command on my dad's kubuntu, but it's kind of in between 0710 & 0804 (let's just say the upgrade is not going smoothly)).

kubuntu workstation installation example:
Code: [Select]
$ sudo apt-get install ruby
$ sudo apt-get install rubygems
$ sudo gem install capistrano

The easiest way to run capistrano is out of a rails application.  This can be just a bare bones rails app.

Code: [Select]
$ sudo gem install rails
$ cd ~
$ rails lmce_manager
$ cd lmce_manager
$ /var/lib/gems/1.8/bin/capify . 
$ vi config/deploy.rb

Here's an example deploy.rb that I'm using for tweaking my dcerouter:
Code: [Select]
set :application, "lmce_manager"
set :repository,  "http://royw-gentoo/svn/linuxmce/trunk/lmce_manager"
set :user, "linuxmce"
set :runner, "linuxmce"

# If you aren't deploying to /u/apps/#{application} on the target
# servers (which is the default), you can specify the actual location
# via the :deploy_to variable:
# set :deploy_to, "/var/www/#{application}"

set :deploy_to, "/var/www/rails/#{application}"

# If you aren't using Subversion to manage your source code, specify
# your SCM below:
# set :scm, :subversion

set :scm_username, 'linuxmce'
set :scm_password, proc{Capistrano::CLI.password_prompt('SVN pass:')}

role :app, "192.168.80.1"
role :web, "192.168.80.1"
role :db,  "192.168.80.1", :primary => true

namespace(:dcerouter) do
desc "setup core/hybrid"
task :setup do
# setup ssh certificates using ssh-installkeys
# (http://www.catb.org/~esr/ssh-installkeys)
# installed locally on workstation (not on lmce system)
`ssh-installkeys linuxmce@192.168.80.1`

# copy hack_xorg_conf from workstation to dcerouter, then run it
# hack_xorg_conf edits /etc/X11/xorg.conf to add "DisplaySize 406 229" to "Monitor" section
put(File.read('/var/dcerouter/hack_xorg_conf'), '/home/linuxmce/hack_xorg_conf')
sudo "chmod 775 /home/linuxmce/hack_xorg_conf"
sudo "/home/linuxmce/hack_xorg_conf"

# increase firefox's font sizes to 16pt
sudo "mkdir /root/.mozilla/firefox/pluto.default/chrome"
put(File.read('/var/dcerouter/.mozilla/firefox/pluto.default/chrome/userChrome.css'),
'/root/.mozilla/firefox/pluto.default/chrome/userChrome.css')
sudo "chown root.root /root/.mozilla/firefox/pluto.default/chrome/userChrome.css"

# create rails directory that user linuxmce has write permission to
sudo "mkdir /var/www/rails"
sudo "chown linuxmce.linuxmce /var/www/rails"
sudo "chmod 775 /var/www/rails"
end

desc "install rails"
task :install_rails do
# we first install the ancient versions furnished via kubuntu,
sudo "apt-get install -y libyaml-ruby"
sudo "apt-get install -y libzlib-ruby"
sudo "apt-get install -y rubygems"
sudo "apt-get install -y ruby1.8-dev"
sudo "apt-get install -y build-essential"

# then we upgrade gem to the the lastest
sudo "gem update -y"
sudo "gem update -y --system"
sudo "rm /usr/bin/gem"
sudo "ln -s /usr/bin/gem1.8 /usr/bin/gem"

# now we install rails and our required modules
sudo "gem install rails"
sudo "gem install composite_primary_keys"
sudo "gem install railroad"
sudo "gem install will_paginate"
sudo "gem install --platform ruby fastthread"
sudo "gem install --platform ruby mongrel"

sudo "apt-get install -y libmysql-ruby1.8"
sudo "apt-get install -y libmysql-ruby"
sudo "apt-get install -y irb"
end
end

Now after an LMCE install I just run:
Code: [Select]
$ cd ~/lmce_manager
$ /var/lib/gems/1.8/bin/cap dcerouter:setup

Presto, my dcerouter is tweaked.

To install rails on my dcerouter:
Code: [Select]
$ cd ~/lmce_manager
$ /var/lib/gems/1.8/bin/cap dcerouter:install_rails

The only downside to Capistrano is the online documentation for version 2.x is sub-par.  The team seems to be working on it at http://capify.org/documentation.  The documentation for 1.3 is available at http://manuals.rubyonrails.com/read/chapter/104.  The book, "Deploying Rails Applications", has a chapter on Capistrano.  IMO, it's an ok intro, but it is not a full reference manual.

Have fun,
Roy

6
Developers / Problem when attempting to remove unused genres
« on: May 22, 2008, 09:14:58 pm »
Howdy,

I'm trying to clean up the list of genres that is displayed on UI2's Video, Genre menu.  My thoughts were to simply remove all of the unused  "Genre" Attributes, like:

Code: [Select]
desc "Remove unused Genre Attributes"
task(:remove_unused_genres => :environment) do
genre_attribute_type = fetch_attribute_type('Genre')
PlutoMedia::LmceAttribute.find_all_by_FK_AttributeType(genre_attribute_type.id).each do |genre_attribute|
if genre_attribute.lmce_files.empty?
puts "Deleting Genre Attribute: #{genre_attribute.Name}"
genre_attribute.destroy
end
end
end

Which does remove all of the Genre Attributes that don't have any File references.

The problem is that the Video, Genre menu now only contains the "All" entry.  I've tried regen'ing the oribiter, reloading the core/hybrid, rebooting, resynchronizing the media, adding a new attribute from the media file sync, restoring the database to it's pre-changed condition.  Nothing seems to work to get the list of Genre.

I've grep'ed in the source code and haven't found anything hinting that the menu requires anything else besides the Attribute and File tables.

I'm hoping some nice guru can point me to where I need to be looking.

Thank you,
Roy

7
Users / Anyone using DVDProfiler?
« on: May 20, 2008, 08:41:38 am »
Howdy,

For years, I've used the shareware DVDProfiler (http://www.invelos.com/) to manage my DVD collection.  The best feature is that I just scan the barcode of new DVDs and I get good data about the dvd.  While the amazon lookup that LMCE uses is ok, it is neither as accurate nor as complete as I am use to.

So I've written a little hack to allow me to sync the LMCE database from my DVDProfiler database.  It is currently something only the programmer who wrote it could love (it's a rails rake task :) ).

What I would like to know is if there is any interest in the community for this application? 


Thank you,
Roy

8
Developers / pluto_main.Package_Version preventing dump
« on: May 20, 2008, 06:03:56 am »
Howdy,

Probably not a common case but thought I'd document an unusual occurrence.

My system was 0710 beta 4 i386 upgraded to RC1 via DVD install with keep database option.

While attempting a database dump of pluto_main I got:
Code: [Select]
linuxmce@dcerouter:~$ mysqldump -u root --databases pluto_main     >pluto_main.sql
mysqldump: Got error: 1146: Table 'pluto_main.Package_Version' doesn't exist when using LOCK TABLES

Here's some investigation using mysql:
Code: [Select]
mysql> use pluto_main;
mysql> show tables;
+--------------------------------------------------+
| Tables_in_pluto_main                             |
+--------------------------------------------------+
...
| Package_Version                                  |
...
mysql> select * from Package_Version limit 1;
ERROR 1146 (42S02): Table 'pluto_main.Package_Version' doesn't exist
mysql> describe Package_Version;
ERROR 1146 (42S02): Table 'pluto_main.Package_Version' doesn't exist
mysql> drop table Package_Version;
ERROR 1051 (42S02): Unknown table 'Package_Version'
Following this advice: http://lists-archives.org/mysql/21070-lock-tables.html I removed Package_Version.frm from the pluto_main database directory:
Code: [Select]
dcerouter_72579:/var/lib/mysql/pluto_main# mv Package_Version.frm ~
Now the dump works:
Code: [Select]
linuxmce@dcerouter:~$ mysqldump -u root --databases pluto_main     >pluto_main.sql
linuxmce@dcerouter:~$ ls -l pluto_main.sql
-rw-r--r-- 1 linuxmce linuxmce 23763604 2008-05-19 20:48 pluto_main.sql

My guess is that Package_Version table was removed for RC1, but the dvd installer did not remove the .frm file.

HTH,
Roy

9
Installation issues / 0710B4 NFS mount points changed?
« on: April 22, 2008, 06:38:18 am »
Howdy,

I just did a 0710 beta 4 DVD i386 install, then added my two NFS drives via admin pages.  What I'm seeing is that the NFS mount points are now under /home/public/data/other/NFS Share [xx].  In beta 3 there were mount points under each of the data/* directories (ex: /home/public/data/videos/NFS Share [xx], /home/public/data/audio/NFS Share [xx]).  Was this an intentional change?

TIA,
Roy

10
Installation issues / hdhomerun video but no audio
« on: April 10, 2008, 09:03:30 am »
Howdy,

Just received my hdhomerun and attempted plug 'n pray.  Everything appeared to install correctly.  But ended up being able to view channels but not hear them.  Updated the firmware to the latest, no change.  Looked around the pluto admin page but didn't see anything wanting me to specify an audio pipe for the hdhomerun.  My core/hybrid pipes output to my AV receiver which works fine for the DVD playback.  I'm still at 0710 beta 3.

Any hints?

TIA,
Roy

11
Developers / script to create ruby ActiveRecord pluto database models
« on: April 09, 2008, 09:08:35 am »
Howdy,

I'm finally starting to feel pretty confident in the models generated by this script so thought I'd share it.  I'm using the models in a media manager that lets you select sets of media objects then perform actions on the sets.  But I'm finding the models very useful to do queries from the rail's console (irb).

This script just queries the mysql pluto databases, then uses the sqlcvs naming convention to create the model associations (belongs_to, has_one, has_many (it doesn't look like pluto uses any pure join tables so there are no has_and_belongs_to_many associations)).

The script is at:  http://roy.wright.org/linuxmce/mysql2models.rb

Here's my notes on setting up a rails project and using this script:
Code: [Select]
# install graphviz to be able to create class diagrams using railroad
# note, railroad and graphviz are development tools, not required
# for our rails application.

# on your dev system, assuming kubuntu for these notes
# install rails and composite_primary_keys gem
$ sudo apt-get install rubygems
$ sudo apt-get install ruby1.8-dev
$ sudo apt-get install build-essential
$ sudo apt-get install rails
$ sudo gem install composite_primary_keys
$ sudo gem install railroad
$ sudo gem install rails
$ sudo gem install mongrel
### select: mongrel 1.1.4 (ruby)
### select: fastthread 1.0.1 (ruby)
$ sudo gem install will_paginate
$ sudo apt-get install libmysql-ruby1.8
$ sudo apt-get install libmysql-ruby
$ sudo apt-get install irb

# on linuxmce box, backup linuxmce database
# create script:  /home/linuxmce/dump_pluto_databases
$ cat dump_pluto_databases
rm pluto_*.sql
mysqldump -u root --databases pluto_media    >pluto_media.sql
mysqldump -u root --databases pluto_main     >pluto_main.sql
mysqldump -u root --databases pluto_myth     >pluto_myth.sql
mysqldump -u root --databases pluto_security >pluto_security.sql
mysqldump -u root --databases pluto_telecom  >pluto_telecom.sql

# copy the databases to your dev system:
scp "linuxmce@192.168.80.1:pluto_*.sql" .

# on your dev system, create script to load pluto databases:
$ cat load_pluto_databases
mysql -u root --password=secret <pluto_main.sql
mysql -u root --password=secret <pluto_media.sql
mysql -u root --password=secret <pluto_telecom.sql
mysql -u root --password=secret <pluto_security.sql
mysql -u root --password=secret <pluto_myth.sql

# install linuxmce database on development system

# create rails project

$ rails media_manager
      create
      create  app/controllers
...
      create  log/test.log

# now we need to generate the models and database hooks for
# the linuxmce databases.  We use mysql2models.rb to do this.
# To see the command line options:

linuxmce/media_manager $ ../mysql2models.rb --help
Generate ActiveRecord models from a pluto sqlCVS mysql database.
Usage: mysql2models.rb [options] db_name1 [db_name2...]
Options:
Usage: mysql2models [options]
    -p PASSWORD                      Database Password (no password is the default)
    -u USER                          Database User (root is the default)
    -g, --[no-]generate              Generate the models for rails (should only do once)
    -r, --[no-]replace               Replace the data models for rails
    -s, --[no-]stdout                Print the data models to stdout
    -d, --[no-]dbconfig              Create a config/database.yml for the databases
    -h, --help                       This usage information

# normally on first creation, you need the -g, -r, & -d options.  You need
# the -p if your database requires a password, which mine does on my
# development system while a LMCE system does not.
# Note, the -g option does take a while as it is calling "script/generate model MODELNAME"
# for each of the database tables.

media_manager $ ../mysql2models.rb -p secret -grd
pluto_main, processing...
pluto_media, processing...
pluto_myth, processing...
pluto_security, processing...
pluto_telecom, processing...
      create  app/models/pluto_security
      create  test/unit/pluto_security
...
      create  test/unit/pluto_main/vert_alignment_table_test.rb

# create rails databases, these are separate from the linuxmce databases

$ rake db:create
$ rake db:migrate

# now to see if it works:

media_manager $ script/console
Loading development environment (Rails 2.0.2)
>>

# hey it didn't blow up, so let's take a look at a table

>> PlutoMedia::File.find(:first)
=> #<PlutoMedia::File PK_File: 1, EK_MediaType: 24, FK_MediaSubType: nil, FK_FileFormat: nil, FK_FileGroup: nil, DateAdded: "2008-01-15 09:49:27", Path: "/home/public/data", Filename: "documents", Missing: 0, IsDirectory: 1, EK_Users_Private: nil, EK_Device: nil, ModificationDate: "2008-04-05 23:40:48", AttrCount: 0, AttrDate: nil, DateLastViewed: nil, IsNew: true, Ignore: false, INode: 507998, MD5: "", Source: "F", psc_id: nil, psc_batch: nil, psc_user: nil, psc_frozen: false, psc_mod: "2008-04-05 23:41:59", psc_restrict: nil>

# cool, so let's see what dynamic associations we have:

>> PlutoMedia::File.find(:first).class.reflect_on_all_associations.collect{|a| a.name}
=> [:picture_file, :user, :bookmark, :picture, :media_sub_type, :cover_art_scan, :disc, :media_type, :file_attribute, :file_format, :rip_status, :device, :file_group, :playlist_entry, :file_user, :attribute, :long_attribute]

# so let's try one of the dynamic associations:

>> PlutoMedia::File.find(:first).media_type
=> #<PlutoMain::MediaType PK_MediaType: 24, Define: "misc_DocViewer", Description: "Doc Viewer", FK_DesignObj: nil, DCEAware: 1, Extensions: nil, Subdirectory: "documents", IsExternalTransmission: false, FK_Pipe: nil, CanBookmark: false, EK_AttributeType_DefaultSort: nil, psc_id: 21, psc_batch: 356, psc_user: 33129, psc_frozen: false, psc_mod: nil, psc_restrict: nil>

Have fun,
Roy

12
Users / Borders of KDE desktop not visible
« on: April 04, 2008, 10:35:28 pm »
On my TV, my KDE desktop was too large.  I.e., I could only see the top half of the main panel, the K menu was totally off the screen, etc.
What I discovered is that my TV has two 16:9 standard modes.  Setting the TV to 16:9 standard2 made the entire KDE desktop visible.  This then resulted in the on-screen orbiter floating in from the borders so had to re-run the video setup.

HTH,
Roy

13
Users / Adjusting KDE display resolution
« on: April 04, 2008, 10:26:36 pm »
Howdy,

On my system, the icons and fonts in the KDE desktop were too small.  My original resolution was 75 dpi.  Adjusting the resolution to 120 dpi is just about right.  Here's how.

You will need to add:
Code: [Select]
DisplaySize X Y
to /etc/X11/xorg.conf under the "Monitor" section where:
Code: [Select]
X = (monitor-width-pixels/desired-dpi)*25.4
Y = (monitor-height-pixels/desired-dpi)*25.4
In my case:
Code: [Select]
X = (1920/120)*25.4 = 406
Y = (1080/120)*25.4 = 229
so my DisplaySize line is:
Code: [Select]
DisplaySize 406 229

HTH,
Roy

14
Users / Adjusting firefox menu font
« on: April 04, 2008, 10:14:21 pm »
On my system, firefox's menus were too small to read.  Here's a way to adjust them.

Create firefox chrome directory for root user:
Code: [Select]
susdo mkdir /root/.mozilla/firefox/pluto.default/chrome
Copy the example userChrome.css file from the linuxmce user account to the this directory:
Code: [Select]
sudo cp /home/linuxmce/.mozilla/firefox/*.default/chrome/userChrome-example.css /root/.mozilla/firefox/pluto.default/chrome/userChrome.css
Set ownership of the chrome directory and contents to root:root
Code: [Select]
sudo chown -R root:root /root/.mozilla/firefox/pluto.default/chrome
Edit /root/.mozilla/firefox/pluto.default/chrome/userChrome.css and add the following:
Code: [Select]
* {
font-size: 16pt !important
}
Adjust the font-size to whatever looks best on your system.

HTH,
Roy

15
Howdy,

My system is:

  N800 orbiter -> core/hybrid -> AV Receiver -> TV

I just got the USB-UIRT to be able to control both the AV Receiver and the TV.  Cool!

Now I have two minor issues.

The first, when adjusting the volume on my AV receiver (yamaha RX-V861), each volume up/down is 0.5 dB.  This is fine on it's remote as you can hold the volume button down and it will repeat about 5 times a second.  But on the N800, each click of the volume button is an entirely new event which takes about a second.  So changing volume is very tedious.  What I would like to do is have it send multiple volume commands for a single click, say send four up commands to increase the volume 2dB per click.  Is this possible?

The second issue is with power on/off.  The AV receiver has discrete on/off while the TV is a Hitachi so only has a power toggle.  The commands work fine for both devices.  The issue is that when turning the display off from the Power menu, the AV receiver is powered off but not the TV.  Ideally I would prefer it the other way, i.e., display on/off means turn TV on/off.  Is this possible?

TIA,
Roy

Pages: [1] 2