User Feedback :: Picture frame with DSL on P133, 32MB RAM with CF!



Hi,
Apologize the long post – I hope that this could help others too…

I am working on a picture frame project with old laptop and ikea frame.
The laptop is HP Omnibook 2000CT Pentium 133, 32MB RAM. It does not have USB and can only boot from floppy or hard disk.
Thanks to the forums, and FAQ and some other pages…I managed. I still have questions though so bear with me please...

What I did:
On the hardware side:
1. Disassembled the laptop and its screen frame
2. Extended the screen wires
3. Prepared special double paspartou frame to fix the screen in correct position
4. Stripped the laptop from harddisk, battery, CD-Rom and floppy
5. Installed CF card with CF / IDE adapter, instead of the harddisk
6. Installed PC Wifi card.
Most of it was no problem, the only more problematic area was figuring out the pins on the 44 mini IDE connector on the motherboard … I am suspired I did not blow the controller up… but after some tests I found the correct configuration.

On the software side:
1. Formatted the CF (IDE) in four primary partitions (approx partition sizes: 70MB, 150MB, 500MB, 260MB)
2. Installed DSL 2.0 in frugal (with grub) on hda1
3. Set up the hda2 to be home, opt and mydsl
4. Copied precropped jpgs to the resolution of the screen, to avoid black stripes around images…
5. Installed HD version of DSL on hda4 using  this as a guide

My initial ambition was to install frugal on hda1 and be able to install feh and unclutter as dsl packages.  I prepared the dsl packages on another (faster and higher memory) machine – enabled apt-get, installed feh and unclutter (separately) and used deb2dsl to make the myDSL packages.
After doing that I tried installing them with no luck at all…I kept getting “no space left” kind-a errors and then DSL was responding with “not found” on a simple “ls”…  I thought that the 32MB RAM on my picture frame was not enough, but step by step testing on my other machine (which was running with toram boot option on 1GB RAM) I noticed that feh and unclutter installation uses barely 4MB, and I had at least 8MB free on my /ramdisk. I did the measurement test beginning with clean boot, then activating apt-get, then installing feh, then installing unclutter and running “free” and “df” on each step to see what happens.
The tests also showed something interesting … the feh package wanted to install itself on /usr/bin, which on my frugal install was read only…  I searched trough the forums but could not find anything on how to either make then read/write, or remaster a new DSL CD that includes the FEH and unclutter in the distribution (not as myDSL, but as a preinstalled package).
So there I came to my current situation where I installed DSL on HD (the hda4 partition on the CF) and then installed feh and unclutter by simple apt-get. Modified the startup files needed and now I have a working frame!!!

But… and here come the questions:
1. I am not sure how much of my CF card is rewritten every time a photo is changed… can I generally somehow see what is written and read from a device during a session and how? Vmstat?
2. How can I proof the file system (all partitions are ext2) so if accidental power cut off occurs the frame will self restore and maintain itself?
3. I never had problem with accidental power cut offs when running in frugal mode. But I was unsuccessful installing feh and unclutter in frugal – do you see any problems with the way I ran it? Can you suggest a way for installation that would allow frugal with feh and unclutter?
4. Can you point me to a instruction (or forum post) describing how to remaster DSL with already installed packages? The only instructions I have found were for including MyDSL on a CD with the DSL… but this does not work for me.

Thanks in advance for all help and let me know if you want to see pictures.
Nikolay

I just completed three frames.  I am running from a frugal install on a 32MB flash IDE adapter.  I am using xv (similar to feh) and unclutter remastered into the compressed KNOPPIX filesytem with a whole bunch of other stuff stripped out. Since I have USB ports, I load the pictures from USB Flash sticks or card readers.

Remaster "how to"

The importatant part is that the "source" directory is the filesystem that will get compressed to newcd/KNOPPIX/KNOPPIX so any changes that you make will now be part of the system installed when DSL starts up from LiveCD or Frugal installs.  In my case I added the xv and unclutter files (less the sources and man pages) and removed just about everything else except X11 (although I removed about 4MB of 75dpi fonts from X11 to make it fit in 30MB).

From my remastered KNOPPIX filesystem I did a frugal_install to the IDE Flash drive at hda1.  (I actually was able to modify the install_frugal.sh script to do it on a card reader and then just put it into the target systems IDE/Flash adapter).

Thanks for the very valuable link mshilly!!
I will be trying out re-mastering this weekend.
Do you mind sharing your "mini" DSL image with xv and unclutter?
It would have been helpful to me to see alternative implementation of picture frame with xv instead of feh.

Below is what i did for a picture frame. I run zgv which does not require X. I had USB available to update the photos, you might try something similiar with cd. I power the machine down and it comes back fine.

I am not a linux guru and dont claim that everything in this document is the best way to do it, but it worked for me.

Installing Damn Small Linux (2.0) on a laptop as a Picture Frame

Do these steps prior to ripping apart the computer. It would suck to rip it apart and not be able to make it work.

Start the computer and get into the system bios and disable the power management options associated with the display.

Boot computer of from dsl cd and at the boot prompt type dsl 2. This will boot dsl into text mode so that we can configure the hard drive.

When booted, at the prompt type cfdisk and press enter to start the hard drive partition software. Start out by highlighting each partition on the drive and Delete them. Once that is done choose New/Primary/55/Beginning. Next select Bootable. Next move down to Free Space and choose New/Primary/10/Beginning, move down to Free Space and choose New/Primary/(remaining space)/Beginning. We have now created the partitions we need. To finish we need to choose Write and yes to write partition table to disk. (Note: you must spell out yes here.) Now you can select Quit.

Next type the following

Mke2fs /dev/hda1 enter
Mke2fs /dev/hda2 enter
Mke2fs /dev/hda3 enter

This will prep the partitions for use.

Type init 6 enter to reboot

Again, boot from the cd and at the boot prompt type install. This will boot dsl and bring you to a menu with install options. Select option 4. Frugal Grub Hard Drive Install. When prompted for a target partition, specify hda1, install from LiveCD, format target partition yes and yes to continue. This will copy DSL to the 55mb hda1 partiton we created. When this is done you can reboot by choosing option 8, but this time boot from the hard drive.

When you reboot you will see a menu prompting you to select a boot option. If your laptop screen supports 1024x768 choose DSL fb1024x768. If all goes well, you will boot into X windows.

Once it boots into X windows you will have a DSLpanel icon on the desktop, click once on it, then click on the Backup/Restore button and type hda2 in the box. Now click Backup and it will save all your current settings. This will also save your settings on shutdown and restore them on power up.

Press Alt-Ctl-Del and this will exit X windows.

Now we will modify the boot menu. Type mount /dev/hda1 enter. We will use nano which is a text editor for editing all files.
Type sudo nano /mnt/hda1/boot/grub/menu.lst enter.
The default setting is to select which menu option it will default to with 0 being the first option. If you choose DSL fb1024x768 and your system is running fine, set the default to 2.
Set the timeout to be 3
Under the timeout option type hiddenmenu
Go down to the line title DSL fb1024x768
On the next line that starts with kernel add write quiet to the end of the line.
Type Ctrl-X and answer Y to save and enter.

If you are network attached: (If you’re not you’re screwed, sorry)
Type sudo dpkg-restore enter
Press enter when it finishes
Next type apt-get install zgv enter
This will go out and grab zgv which is the software we will use to display our pictures, as well as additional files needed to support it.

Now that we have installed the software we need to tell it to make sure we Backup and Restore the files.

Type the following:

Cd enter
Nano .filetool.lst enter (note the period in front of filetool. This is a hidden file)

Add the following lines to the bottom of the file
etc/zgv.conf
etc/vga/libvga.config
usr/bin/zgv
usr/lib/libpng.so.2.1.0.12
usr/lib/libvga.so.1
usr/lib/libvga.so.1.4.3
usr/lib/libvgagl.so.1
usr/lib/libvgagl.so.1.4.3

(note all files listed above with version numbers are subject to change and may be different on your system. Please verify the files and versions and fix the names as needed)

Next we need to edit our config files.
Type sudo nano /etc/zgv.conf enter
Scroll down to the line viewer-start-mode and if you are running 1024x768 change the line to be viewer-start-mode 1024 768 24. Next scroll all the way to the bottom and add the following:
Slideshow-delay 30
Slideshow-loop on

The slideshow-delay is how frequently you want your picture to change.
Type Ctrl-X to Exit and save.

Next type sudo nano /etc/vga/libvga.config enter
Scroll down until you come to the Mouse type: section. At the bottom of this section you will see mouse not configured, change it to say mouse PS2 or mouse none.
Type Ctrl-X to Exit and save.

I use a USB memory stick to update my Picture Frame software. On my Windoze XP system I install the XP Power Toy Image resizer available here:

http://download.microsoft.com/downloa....tup.exe

Now on your USB memory stick create a folder called photos and copy the jpg files you want to upload to your picture frame to the folder. Once you have all the photos on the memory stick in explorer highlight all the files and right click on them and choose Resize pictures. I choose 1024x768 (because my laptop can display this), choose advanced and choose to Resize the original pictures. (NOTE make sure you are resizing the copies of the photos you put on the USB memory stick)

Next we need to create an autorun.sh file in the root of the USB memory card. Put the following in the file:

echo Found USB Memory
sudo mount /dev/hda3 -o remount,rw
cd /mnt/sda1/photos
echo Removing old photos from picture frame
rm /mnt/hda3/photos/*.jpg
echo Uploading new photos from USB Memory
cp *.jpg /mnt/hda3/photos/.
sudo mount /dev/hda3 -o remount,ro
cd /

save the file and unplug the USB memory.

Plug the USB memory into the picture frame

Now we need to configure the drive partition for our pictures.
Type the following:

mount /dev/hda3
cd /mnt/hda3
sudo mkdir photos
mount /dev/sda1
cp /mnt/sda1/photos/*.jpg /mnt/hda3/photos/.
Umount /dev/sda1

Remove the USB memory

Now that we have configured the screenshow software and loaded some images it is time to test it.

Type zgv /mnt/hda3/photos/*.jpg enter

If everything is right your screenshow should start. If you see a blank screen or a screen that looks like a TV with vertical/horizontal hold problems, then we need to tweak the libvga.config file.

If you have an older laptop you might see a blank screen, in that case I modified the libvga.config file and found the line that says # chipset VESA and removed the # and tried the slideshow again.

On one machine that looked like the vertical hold was off, I had to adjust the HorizSync line to match my display.

That is about the extent of my knowledge on modifying that file.

OK, we are almost done.

Next we need to tell the system not to start X windows.
Type cd enter
Nano .bash_profile (Note the period in front of bash)
Put a # in front of the line: if [ -z “$SSH” ]; then startx; fi
Ctrl-X Save and Exit

You can always restart X windows by typing startx at the command line if you need to.

Now one last file:
Sudo nano /opt/bootlocal.sh
Add the following to the bottom of the file:
Mount /dev/hda3
Sudo mount /dev/hda3 –o remount,ro

Mount /dev/sda1
/mnt/sda1/autorun.sh
umount /dev/sda1

zgv /mnt/hda3/photos/*.jpg

Ctrl-X Save and Exit.
At this point type sudo init 6 enter

This will backup the required files and reboot. If all goes well, your system will automatically start the slideshow on startup.

To Update Photos
Update and resize the photos on the USB Memory card. Powerdown the Picture Frame, insert the USB memory and reboot. You will see a message during boot that it has Found USB Memory. This will delete all pictures currently on the Picture Frame and will upload all the pictures on the USB memory. Once it is done it will unmount the USB memory and start the slideshow with the new pictures. When the slideshow starts it is safe to remove the USB memory card.

When you have the software working, now is the time to go out and get your shadow box or frame and parts and rip the laptop apart.

If you install the imagemagick.tar.gz extension

http://distro.ibiblio.org/pub....ck.info

from the mydsl repository, you can resize the pictures from inside your Linux frame as part of the importation process.

Imagemagick contains commandline image manipulation utilities.

Next Page...
original here.