Posts Tagged ‘debian’

making stop-motion videos

Friday, September 10th, 2004

This evening Griffin and I made some stop-motion videos using some clay figures he made and my HP camera.

[Take a look](http://www.nozell.com/blog/data/griffin-video-02.avi)

This is how we did it:

* Set the HP 318 Camera to the lowest resolution, turn off flash
* Screw in the little tripod I got years ago for one of the first webcams
* Have plenty of light
* Take about 90+ photos
* dump onto my Linux/Debian laptop (gphoto2 –get-all-files)
* Convert to an animated gif ( convert -delay 10 IM*.jpg out.gif) with a 10/100 second delay. Realize it is a huge 20M file
* Convert to AVI ( mencoder “mf://IM*.jpg” -mf type=jpg:fps=7 -ovc lavc -o output.avi) which gives a much smaller (~1M) file.

Repeat until the batteries need to be recharged.

flickr upload for gnome’s nautilus

Saturday, September 4th, 2004

This evening I noticed that there was a new perl module in CPAN by CPB Flickr::Upload. So I hacked together a Nautilus script to integrate Flickr.com uploads with the Gnome file manager.

If you want to give it a try,

* Install the perl module Flickr::Upload using either CPAN or download from http://search.cpan.org/~cpb/
* Grab this script
* put it in your ~/.gnome2/nautilus-scripts directory
* edit the following lines for your own use:


my $FLICKREMAIL = 'your-flickr@email-address-here.com';
my $FLICKRPASSWORD = 'somesekretword';
my $FLICKRTAGS = 'i like traffic lights'; # space separated list

It works find on my debian/sarge laptop, but should work fine on any other gnome desktop.

Patches would be welcome.

festival speech synthesis on my debian laptop

Wednesday, August 25th, 2004

Last night I was mucking around with festival, the text to speech tool (ala the old DECtalk. On my [laptop](http://h10010.www1.hp.com/wwpc/us/en/sm/WF05a/321957-64295-89315-321838-f33-367367.html) it was speaking too fast.

The solution is found in the Festival FAQ: Running Festival

Create the file festival/lib/siteinit.scm (if you don’t already have it) and add the following

(Parameter.set 'Audio_Method 'Audio_Command)

(Parameter.set ‘Audio_Command “sox -t raw -sw -r $SR $FILE -c2 -t ossdsp /dev/dsp”)

On debian, you put those two lines in /etc/festival.scm

HP, Motorola, Debian Linux

Monday, August 16th, 2004

HP LogoHP just won a large contract with Motorola which includes Debian running on Itanium.

From InternetNews, [HP Get Call for Carriers](http://www.internetnews.com/dev-news/article.php/3395271)

“Virtually each of the network equipment providers is migrating to next-generation platforms based on Linux,” Joy King, HP director of its worldwide marketing for its network and service provider business, told internetnews.com.

HP has modified the Debian Linux distribution to optimize it for carrier grade systems

Also in CNET, [Motorola and HP in Linux tie-up](http://news.com.com/Motorola+and+HP+in+Linux+tie-up/2100-1039_3-5311739.html) and Information Week [Motorola To Incorporate Integrity Systems Into 3G Call Path](http://informationweek.com/story/showArticle.jhtml?articleID=29100410)

netjuke from source on debian

Wednesday, September 3rd, 2003

The debian/sarge package for netjuke didn’t quite work out of the box and it was a little dated so I decided to install netjuke from source.

Dependancies — apt-get the debian packages for mysql-client, mysql-server and make sure php4 and php4-mysql are installed.

Be sure to follow the post-installation steps of php4 in /usr/share/doc/php4/README.Debian.gz.
In particular, un-comment the line:

LoadModule php4_module /usr/lib/apache/1.3/libphp4.so

Uncomment:

AddType application/x-httpd-php .php .phtml .php3
AddType application/x-httpd-php-source .phps

and add index.php to the line like this:

DirectoryIndex index.php index.phtml index.php3 index.html

Remember to restart apache (/etc/init.d/apache restart)

Now you need to create a database to hold the netjuke tables. If you
have an existing database and user, you can use that. I have fresh
MySQL install with no table nor any non-root database users, so I did
this:

  • By default debian’s MySQL server doesn’t listen on the network
    port but netjuke wanted to connect that say, so edit /etc/mysql/my.cnf
    to enable it by commenting out the skip-networking line and
    restart MySQL (/etc/init.d/mysql restart)
  • Check to see that it worked:

    $ mysqladmin -u root password ’sekert’
    $ mysqladmin -u root -p create netjuke
    Enter password:
    $ mysql -u root -p mysql
    Enter password:

    Welcome to the MySQL monitor. Commands end with ; or g.
    Your MySQL connection id is 6 to server version: 4.0.13-log

    Type ‘help;’ or ‘h’ for help. Type ‘c’ to clear the buffer.
    mysql> grant all privileges on netjuke.* to netjuke@localhost
    identified by ‘othersekret;
    Query OK, 0 rows affected (0.01 sec)

  • Now you are ready to install netjuke.

    Go to the top of the web space, by default on debian it is /var/www
    and unpack netjuke (tar zxvf ~/ netjuke-1.0-rc2.tar.gz).

    Now as the netjuke docs say, go to http://127.0.0.1/netjuk
    e/installer/installer.php

    and click through the GPL license to the installation page. My
    answers were:

    DB Type: MySQL
    DB Host: localhost
    DB User: netjuke
    DB Password: othersekret
    Sys. Admin. email: marc@nozell.com
    Admin Password: moresekret
    

    After a submit (be sure javascript is enabled, netjuke uses it
    heavily) it will offer to save inc-prefs.php. Copy that to
    /var/www/netjuke/etc/ and you may need to set the privileges to the
    web server can read the file

    chmod 444 /var/www/netjuke/etc/inc-prefs.php

    You are almost done, so take a look at http://localhost/netjuke and
    log in and poke around some. Don’t worry that there aren’t any music
    files there, that is next.

    I keep my music files in /DATA/Music/ and didn’t want to copy them to
    where netjuke wanted them (/var/www/netjuke/var/music), so I used
    ln to make them available like this:

    cp /var/www/netjuke/var/music/* /DATA/Music
    rm -rf /var/www/netjuke/var/music
    ln -s /DATA/Music /var/www/netjuke/var/music
    

    Now back to netjuke’s web
    interface
    to import the files. Follow the links Admin->Recursive
    Audio File Finder->Start Scanning and then watch as the mp3/ogg/etc
    files are found and added to the netjuke database. If you have a lot
    (I have around 11G) you may need to import them a few at a time using
    the Admin->Music Directory Browser route and bring in a few
    directories at at time.

Using X10 to control the kid’s lava lamp

Monday, September 1st, 2003

Installed bottlerocket (comma nd is br) and setup cron to turn on/off the boy’s lava lamp so it is on when the wake up and go to bed.

My root crontab looks like this now:

MAILTO=marc

# Turn on Spencer's lava lamp at 6:00am and off at 7:30pm
0 6 * * *       /usr/bin/br A3 ON
0 7 * * *       /usr/bin/br A3 OFF

# Turn on Spencer's lava lamp at 7:30pm and off at 8:30pm
30 19 * * *       /usr/bin/br A3 ON
30 20 * * *       /usr/bin/br A3 OFF

Using MTRG to monitor kid’s bandwidth

Monday, September 1st, 2003

We just added a WinXP system for the kids to use. We were tired of saying: “Stop playing neopets on Mom’s computer” and “Enough of the Strong Bad email, get off of my computer”. In order to keep an eye on how much bandwidth they were using, especially if they inadvertently get install some spyware, I’m using MRTG to watch for spikes in traffic.

  • On the windows systems, install SNMP (in the control panel->Add Software->Add/Remove Windows Components).
  • On the home linux server install mrtg
    and then do this:

  • Create a mrtg configuration file:
    cfgmonitor public@kidspc public@wendypc > /etc/mrtg.cfg 
  • Create a index for the top of the web area:
    indexmaker /etc/mrtg.cfg > /var/www/mrtg/index.html 

The debian package already took care of creating the directory and a
script in /etc/cron.d/mrtg to run every 5 minutes.

Printing to a microsoft windows-hosted printer from debian

Wednesday, August 13th, 2003

Our HP
PSC 750 color flatbed all-in-one printer/copier/scanner
is
connected to a Microsoft Window2000 desktop and I want to print to it
from the home linux server as well as my laptop when I’m home.

First ‘unix printing’ support needs to added to the w2k system. Go to
Control Panel->Add/Remove Programs and then select ‘Add/Remove Windows
Components’ on the left sidebar. From there install ‘Other Network
File and Print Services’ where you will see ‘Print Services for
Unix’. Then under the Printers control set the printer as Shared and
name it something, I chose ‘allinone’.

Then install the following debian packages:

cupsys — Common UNIX Printing
System(tm) - server
cupsys-bsd — Common UNIX
Printing System(tm) - BSD commands
cupsys-client — Common
UNIX Printing System(tm) - client programs (SysV)

And then point a web browser to http://localhost
:631
(or
http://<homeserver>:631), authenticate with the root password.
From there, follow ‘Manage Printers’ and add one as follows:

  • queue name: allinone or whatever you like. Description and location are op
    tional
  • Device: LPD/LPR Host or Printer
  • Device URI: lpd://192.168.1.100/allinone — That is the local IP
    address of the w2k system and allinone is the Windows name for that
    printer
  • Pick the appropriate printer driver, in my case it is HP then ‘HP New Deskj
    et Series CUPS v1.1 (en)’
  • Then configure the printer options if you want to.

Now you can print a job as simply as ‘lpr -Pallinone filename.txt’ or ‘lpr -Pal
linone filename.ps’

While I was at it, I hooked up an old epson color printer to the linux home ser
ver too.

bottlerocket to control X10 ‘firecracker’

Wednesday, August 13th, 2003

I finally found some time to cleanup/mess around in the home office
and plugged the X10 ‘firecracker’ into the new home linux server.

Now br A1 OFF turns off the light in my office and
br A2 ON turns on the lava lamp in the older boy’s room. Now
to use cron to turn off the lava lamp so I don’t have to worry that
the boys forgot to.

bottlerocket &mdash Utility t
o control X10 Firecracker devices

More essential software for a home linux server

Monday, July 28th, 2003

Time to (re)install an IMAP server on the home server. Using

mu
tt
-f {homeserver}inbox

is much nicer than the
m
ail -f
~/ImapFolders/inbox

uw-imapd - remote mail folder acc
ess server

While the debian package will create its own certificate, take a look
at my old
note at how to create a self signed certificate for IMAP
.

squid also needed a little configuration to allow for the Using
ssh to pierce corporate firewalls
hack.

In /etc/squid.conf, add a line like this:

http_port 127.0.0.1:3128

Now this works again:

ssh -f -C -L 8080:127.0.0.1:3128 -l marc 192.168.1.200 sleep 1000