Thread: iLiad Bricked My Iliad
View Single Post
Old 03-21-2007, 07:30 PM   #7
Alexander Turcic
Fully Converged
Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.Alexander Turcic ought to be getting tired of karma fortunes by now.
 
Alexander Turcic's Avatar
 
Posts: 18,175
Karma: 14021202
Join Date: Oct 2002
Location: Switzerland
Device: Too many to count here.
Adam,

I don't see anything inherently dangerous in your script; but is it possible that mpc did something unexpected which could have led to you bricking your device? Specifically, what about these commands:

/mnt/card/mpd/bin/mpc clear
/mnt/card/mpd/bin/mpc update
/mnt/card/mpd/bin/mpc listall | mpc add -
/mnt/card/mpd/bin/mpc playlist > playlist.txt

Code:
#!/bin/sh
##MPD Playlist Script for ContentLister
killall mpd
/mnt/card/mpd/bin/mpd mpd.conf
cd /mnt/card/Music/Playlist/
rm -rf *
/mnt/card/mpd/bin/mpc clear
/mnt/card/mpd/bin/mpc update
/mnt/card/mpd/bin/mpc listall | mpc add -
/mnt/card/mpd/bin/mpc playlist > playlist.txt
int=1
file=playlist.txt
while read i 
do
      
      mkdir /mnt/card/Music/Playlist/$int
      cd  /mnt/card/Music/Playlist/$int
      touch manifest.xml
      echo "<xml>\n<package>\n  <metadata>\n    <dc>\n      <Title>$i</Title>\n      <Description></Description>\n      <Date>2006-11-16T08:28:46</Date>\n      <Identifier>\n      <Language>\n      <Type>\n    </dc>\n    <y>\n      <startpage>run.sh</startpage>\n      <version>000</version>\n    </y>\n  </metadata>\n</package>\n" >> manifest.xml
      touch run.sh
      echo "/mnt/card/mpd/bin/mpc play $int" >> run.sh
      chmod a+x run.sh
      int=`expr $int + 1`
done < "$file"
Alexander Turcic is offline   Reply With Quote