Join Today
+ Reply to Thread
Results 1 to 5 of 5
  1. #1

    Default Auto wallpaper changer shell script

    Someone has whipped up a shell script for auto wallpaper n startup/shutdown changing to be used on A780.. the installatin file is in mpkg format.... any experts could port it over to E680 for use?

    the script is as follows:

    #!/bin/bash

    if [ -e /tmp/newphoto.cfg ]
    then
    /usr/SYSqtapp/mystuff/mystuff
    exit
    fi

    photodir=/mmc/mmca1/pictures/

    cd $photodir

    tmpnum=`try_time| sed "s/[^0-9]//g" `
    RANDOM=$(( $tmpnum - ( $tmpnum / 10000 * 10000) ))
    echo "\$RANDOM="$RANDOM

    wallpaper_num=$(( `ls|grep -v -c .gif$` * $RANDOM / 10000 + 1 ))
    echo "\$wallpaper_num="$wallpaper_num
    newwallpaper=`ls|grep -v .gif$ | sed -n ${wallpaper_num},${wallpaper_num}p`
    echo "\$newwallpaper="$newwallpaper


    gif_num=$(( `ls|grep -c .gif$` * $RANDOM / 10000 + 1 ))
    newdowngif=`ls|grep .gif$ | sed -n ${gif_num},${gif_num}p`
    echo "\$newdowngif="$newdowngif

    tmpnum=$((`try_time| sed "s/[^0-9]//g" ` / 10 ))
    RANDOM=$(( $tmpnum - ( $tmpnum / 10000 * 10000) ))
    echo "\$RANDOM="$RANDOM

    gif_num=$(( `ls|grep -c .gif$` * $RANDOM / 10000 + 1 ))
    newupgif=`ls|grep .gif$ | sed -n ${gif_num},${gif_num}p`
    echo "\$newupgif="$newupgif

    downgif=${photodir}$newdowngif
    upgif=${photodir}$newupgif
    wallpaper=${photodir}$newwallpaper

    echo $downgif
    echo $upgif
    echo $wallpaper

    echo "ThemePowerDownImage = $downgif" > /tmp/newphoto.cfg
    echo "ThemePowerUpImage = $upgif" >> /tmp/newphoto.cfg
    echo "ThemeWallpaperFile = $wallpaper" >> /tmp/newphoto.cfg

    grep -v -E "ThemeWallpaperFile|ThemePowerDownImage|ThemePowerUpImage" /ezxlocal/download/appwrite/setup/ezx_theme.cfg > /tmp/theme.tmp
    sed -e '/ThemeName/r /tmp/newphoto.cfg' /tmp/theme.tmp > /ezxlocal/download/appwrite/setup/ezx_theme.cfg

    /usr/SYSqtapp/mystuff/mystuff

  2. #2

    Default Re: Auto wallpaper changer shell script

    Is the MPKG file directly installable on the 780? if so can we get a copy to see if that format can be used to install stuff onto the e680?

    thanks

  3. #3
    Join Date
    Feb 2005
    Location
    Singapore
    Posts
    3,206

    Default Re: Auto wallpaper changer shell script

    wads in newphoto.cfg?
    My favorite Motorola development site!


  4. #4
    Join Date
    Feb 2005
    Location
    sg<br>Mobile: e680 -> i (c5a4p)
    Posts
    1,412

    Default Re: Auto wallpaper changer shell script

    yup i wanna see the mpkg file too. my guess is it might be similar to ipk and mtf. just a gzip or ar file containing maybe some meta-data. you have any mpkg luckydip?

  5. #5

    Default Re: Auto wallpaper changer shell script

    this is the mpkg file...u can use winrar to open the package 3X
    Attached Files Attached Files


 
+ Reply to Thread

Similar Threads

  1. Replies: 35
    Last Post: 07-09-2010, 01:38 PM
  2. Automatic wallpaper changer
    By kamesh in forum E6 General Chat
    Replies: 4
    Last Post: 07-18-2009, 01:50 PM
  3. NEW APP:Magic - Automatic wallpaper changer
    By longnhi in forum E680i General Chat
    Replies: 9
    Last Post: 05-05-2008, 03:49 AM
  4. Help ! How to run a shell SCRIPT as a root?
    By CLOVIS KKK in forum A1200 General Chat
    Replies: 2
    Last Post: 01-25-2007, 03:02 PM
  5. How to Auto Start a Script on phone start
    By mudassar in forum A780 General Chat
    Replies: 8
    Last Post: 12-20-2005, 09:46 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Single Sign On provided by vBSSO

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1