#!/bin/sh # DLNAサーバー名(http://KURO-BOX/dlna/で表示される名称) dlnaserver="RD-E300" # 番組保存用ディレクトリのパス moviedir="/mnt/movie" # 番組ファイル名のエンコード charset="EUC-JP" # ネットdeナビのユーザー名とパス(電源Offコマンド用) id="admin" pass="passwd" # VARDIAのMACアドレス(ネットdeナビ設定等を参照) etherwake 00:15:b7:xx:xx:xx # 起動待ち時間(秒) sleep 80 curl -o temp.html http://localhost/dlna/ >/dev/null 2>&1 uri=`sed -n -e 's/^.*href="//' -e "s/\">\${dlnaserver}.*$//p" temp.html` if [ -n $uri ]; then ip=`echo "$uri" | sed -e 's/^\/dlna\///' -e 's/:[0-9]*\/?usn=.*$//'` curl -o temp.html "http://localhost${uri}" >/dev/null 2>&1 uri=`sed -n -e 's/^.*href="//' -e 's/">video.*$//p' temp.html` curl -o temp.html "http://localhost${uri}" >/dev/null 2>&1 uri=`sed -n -e 's/^.*href="//' -e 's/">publicVideo.*$//p' temp.html` curl -o temp.html "http://localhost${uri}" >/dev/null 2>&1 num=`grep 'a href=' temp.html | tee temp.lst | wc -l` i=1 while [ $i -le $num ]; do title=`sed -n -e 's/^.*csi">//' -e 's/:[0-9][0-9]<\/td>