pBurn 4.3.19

Audio editors, music players, video players, burning software, etc.
Message
Author
User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#141 Post by zigbert »

I'm very pleased by your help here, Mike. Your verify code works perfect in Pburn, and have joined the rest of the code. However, it fails when burning multisession. Either we have to write our own diff-check, or just give verify-option when burning single session.

Have you looked at the iso-verifying?

When posting hacked files, it would be useful if you commented changed lines with #mikeb.

Thanks a lot
Sigmund

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#142 Post by mikeb »

However, it fails when burning multisession. Either we have to write our own diff-check, or just give verify-option when burning single session.
Well for me it passes the last session as ok but fails on the previous sessions as they are only on disk...perhaps grep for the currently burned results using the burnlist entries..I'll have a fiddle with that one.
Plus generally perhaps some handling to simply return 'verify ok' if all verifies sucessfully.
Have you looked at the iso-verifying?
Not yet but burniso2cd compares the md5 checksum as a verify so perhaps use code from there?
When posting hacked files, it would be useful if you commented changed lines with #mikeb.
good point...I iz such a slob :D

By the way my method of showing/not showing the verify is a bit sloppy...the pmount method would be neater.

regards

mike

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#143 Post by zigbert »

By the way my method of showing/not showing the verify is a bit sloppy...the pmount method would be neater.

I've restructured your code a bit. Here are the latest func_exec

Code: Select all

#!/bin/sh

export LOG="/tmp/pburn-log"
echo -e "\c" > /tmp/pburn-log
"$APPDIR"/func -logbox &
#---
#TMP=`cat /tmp/pburn-exec | grep cdrecord` #to get correct linespacing i Xdialog logbox --> slow render on older cpu
#sed -i -e "s%$TMP%$TMP | tr '\r' '\n' %g" /tmp/pburn-exec'
#---
while [ 1 ]; do #burn-again-loop
	chmod 700 /tmp/pburn-exec
	/tmp/pburn-exec >> $LOG 2>&1
	TMP=$?
	#define if info about iso-image should be shown
	TXT_IMAGE="-"
	if [ `find "$OUTDIR/Pburn.iso"` ]; then
		TXT_IMAGE="

$LOC405 $OUTDIR"
	fi
	if [ $TMP != 0 ]; then
		if [ $EJECT = true ]; then
			eject $BURNDEV
		fi
		#ERROR
		ERROR="<b>Unknown error.</b>"
		if test "`cat $LOG | grep "No disk"`";			then ERROR="$LOC387"; fi
		if test "`cat $LOG | grep "Cannot load"`";		then ERROR="$LOC388"; fi
		if test "`cat $LOG | grep "Joliet"`";			then ERROR="$LOC392"; fi
		if test "`cat $LOG | grep "No such device"`";	then ERROR="$LOC393"; fi
		if test "`cat $LOG | grep "overburn"`";			then ERROR="$LOC394"; fi
		if test "`cat $LOG | grep "No space left"`";	then ERROR="$LOC389"; rm "$ISOFILE"; fi
		if test "`cat $LOG | grep "BLANK media"`";		then ERROR="$LOC397"; fi
		if test "`cat $LOG | grep "next writable add"`";then ERROR="$LOC398"; fi
		TXT1="$ERROR......$LOC399"
		TXT2="$TXT_IMAGE"
		. "$APPDIR"/box_ok
		break
	else
		#finished
		while [ 1 ]; do #verify-loop
			
			if [ $BURN_DATA = true ] && [ ! "$SECTIONS" ]; then #it's a DATA single session, and verify works.
				GUI_VERIFY="<button><input file icon=\"gtk-apply\"></input><label>$LOC409</label><action type=\"exit\">verify</action></button>"
			fi
			export finish_box="
			<window title=\"Pburn $VERSION\" icon-name=\"gtk-cdrom\">
			 <vbox>
			  <frame $LOC406>
			   $SPLASH
			   <text use-markup=\"true\"><label>\"$LOC407\"</label></text>
			   <text><label>$TXT_IMAGE</label></text>
			  </frame>
			  <hbox>
			   <button>
			    <input file icon=\"gtk-cdrom\"></input>
			    <label>$LOC408</label>
   			    <action type=\"exit\">repeat</action>
			   </button>
			   $GUI_VERIFY
			   <button>
			    <input file icon=\"gtk-quit\"></input>
			    <label>$LOC406</label>
			   </button>
			  </hbox>
			 </vbox>
			</window>"
			#show verify box if it is a DATA disc
			I=$IFS; IFS=""
			for STATEMENTS in  $(gtkdialog3 --program=finish_box --center); do
				eval $STATEMENTS > /dev/null 2>&1
			done
			IFS=$I
			case $EXIT in
			verify)
				mkdir /tmp/verify 2>/dev/null
				mount $BURNDEV /tmp/verify -t iso9660
				echo -e "\n\n======================================================\n$LOC431...\n" >> $LOG
				diff -s -r --speed-large-files /tmp/verify /tmp/pburn >> $LOG
				echo -e "\n...$LOC432" >> $LOG
				umount $BURNDEV
				;;
			repeat)
				break
				;;
			*)
				. "$APPDIR"/func -new
				if [ $EJECT = true ]; then
					eject $BURNDEV
				fi
				kill -9 `ps -eo pid,command | grep -i "pburn" | grep -i "gtklogfileviewer" | grep -v grep | awk '{print $1}'`
				rm -f "$OUTDIR"/Pburn.iso > /dev/null 2>&1
				rm -f "$OUTDIR"/pburn-audiocd.bin > /dev/null 2>&1 #cdrdao
				rm -rf "$OUTDIR"/pburn_tmp > /dev/null 2>&1
				exit
				;;
			esac
		done
	fi
done #repeat-action-loop

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#144 Post by mikeb »

Ok

Thanks for passing that on
:)
MIke

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#145 Post by mikeb »

Code: Select all

diff -r --speed-large-files /tmp/verify /tmp/pburn | grep -v verify: >> $LOG
will only output errors, and errors from files that are only exist on the disk ie from a previous session will be ignored....so a good multisession burn would output nothing...

mike

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#146 Post by zigbert »

great!!!

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#147 Post by mikeb »

Goodly :)

by the way I had to change at around line 110 in func in the import_session section from

Code: Select all

mount -a $BURNDEV /tmp/pburn-mnt
to

Code: Select all

mount $BURNDEV /tmp/pburn-mnt -t iso9660
mike

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#148 Post by zigbert »

How to make a Pburn Theme
- Themes are put in /usr/local/pburn/themes/NAME_OF_THEME/
- You can freely use the size of images that you feel look best. (Buttons height should not be more than 63 pixels)
- Use *.png format.
- You can also specify a unique gtk-theme for Pburn main window. This is put inside /usr/local/pburn/themes/NAME_OF_THEME/gtk/
- If using same image in several dialogs, - make a symlink to save space.

See theme 'Pburn-original' for complete file list.
Download: Pburn-original (84 kb).


Good luck!
Sigmund
Last edited by zigbert on Mon 17 Mar 2008, 19:05, edited 7 times in total.

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#149 Post by mikeb »

Iso verifying

Here is a slightly modded version of the verify from burniso2cd...added stat -L option to work through symlink...written by kirk...

Code: Select all

ISOFILE="/tmp/pburn/boot.iso"
CDR="/dev/hdc"

  if [ "$( md5sum $ISOFILE | cut -f 1 -d " " )" = "$(dd if=$CDR | head -c `stat -L --format=%s $ISOFILE` | md5sum | cut -f 1 -d " " )" ] ;then 
   xmessage -bg "#80ff80" -center -name "Pburn" -title "Burniso2cd: Burn Verify" -buttons "OKAY:10" "The burn has been verified as good!"
  else
   xmessage -bg "#ffc0c0" -center -name "Pburn" -title "Burn Verify" -buttons "OKAY:10" "The burn was not verified. "
  fi
Have been testing as standalone script plus I don't have a dvd burner to test with. The disk does NOT need mounting.

On a side note, burn command breaks if there is a space in the path to the iso.

Mike

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#150 Post by zigbert »

Mike
You are a hard working man!
I'll look at this in the morning.
It's late in Norway right now.


Good night
Sigmund

User avatar
ttuuxxx
Posts: 11171
Joined: Sat 05 May 2007, 10:00
Location: Ontario Canada,Sydney Australia
Contact:

#151 Post by ttuuxxx »

zigbert wrote:How to make a Pburn Theme
Themes are put in /usr/local/pburn/themes/NAME_OF_THEME/image.png
Install the theme Pburn-original to see how that works.

You can freely use the size of images that you feel look best.
Use *.png format.
You can also specify a unique gtk-theme for Pburn. This is put inside /usr/local/pburn/themes/gtk/.
If using same image in several dialogs, - make a symlink to save space.
See theme Pburn-original for complete file list.

Theme: Pburn-original (151 kb).


Good luck!
Sigmund
that sounds excellent and so easy :)
http://audio.online-convert.com/ <-- excellent site
http://samples.mplayerhq.hu/A-codecs/ <-- Codec Test Files
http://html5games.com/ <-- excellent HTML5 games :)

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#152 Post by zigbert »

I have made a edit on the theme post. - Button images shoudn't be higher than 63 pixels.

Also MU helped out to change the radiobuttons in the main window. See this. http://www.murga-linux.com/puppy/viewto ... 053#179053

Sigmund

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#153 Post by zigbert »

Version 1.2.0 is uploaded. See main post.

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#154 Post by zigbert »

I have tweaked the original theme. It mainly look the same, but now it is only 89kb compared with the old version of 152kb. To handle this tweak you need the new Version 1.2.1. see main post.

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#155 Post by mikeb »

Hi Zigbert

something resembling the following is needed in func_exec just before
done #repeat-action-loop right at the end

Code: Select all

	eject $BURNDEV 
	IMG="dialog-info"; FRAME="Repeat Burn"
	TXT1="Please insert blank disk.
Press OK when ready."
	. "$APPDIR"/box_ok
in order that the disk can be changed for repeat burns.

Haven't progressed with the iso verify as all my cd/rw's are past their useful life so not ideal for checking for good burns :? ..

Nice one for the verify implementation and skinning functionality...

ok, off to melt some silver.............

mike

also

added to func_blank

Code: Select all

fi

[u]export BURN=blank # to avoid verify message[/u]

if [ "$MEDIATYPE" = "CD" ];then
and amended in func_exec

Code: Select all

if [ $BURN_DATA = true && $BURN != "blank" ]; then #verify button
.....removes verify button etc when blanking without (as far as I can tell) other functions.[/code]
Last edited by mikeb on Sat 08 Mar 2008, 02:29, edited 1 time in total.

User avatar
WhoDo
Posts: 4428
Joined: Wed 12 Jul 2006, 01:58
Location: Lake Macquarie NSW Australia

What did I do wrong?

#156 Post by WhoDo »

I'm running Pburn 1.2.1 and I have downloaded the original theme supplied by zigbert, but I can't get Pburn to display that theme presumably because nothing happens when I click "Preferences" in the File menu.

Any ideas?
[i]Actions speak louder than words ... and they usually work when words don't![/i]
SIP:whodo@proxy01.sipphone.com; whodo@realsip.com

xekarfwtos
Posts: 7
Joined: Tue 19 Feb 2008, 08:57

#157 Post by xekarfwtos »

I have the same problem.

I'm running Pburn 1.2.1 in Puppy 3.01 (frugal) I have downloaded the original theme, but nothing happens when I click "Preferences" in the File menu or "Advanced search".

If i run it from console, I get
cat: /root/.gtkrc-2.0: No such file or directory
cat: /root/.gtkrc-2.0: No such file or directory
when I hit "Preferences", I get
cat: /root/.gtkrc-2.0: No such file or directory

** ERROR **: gtkdialog: Error in line 49, near token '</default>': syntax error

aborting...
when I hit "Advanced search", I get
** ERROR **: gtkdialog: Error in line 43, near token '</default>': syntax error

aborting...
rm: cannot remove `/tmp/pfilesearch*': No such file or directory
cat: /root/.gtkrc-2.0: No such file or directory
edit:

I delete /root/.pfilesearch and run pfilesearch. Then I run pburn and works fine.

User avatar
zigbert
Posts: 6621
Joined: Wed 29 Mar 2006, 18:13
Location: Valåmoen, Norway
Contact:

#158 Post by zigbert »

Thank you guys for your bugreports. Try this new version uploaded. But before that, please install the newest [url=
http://www.murga-linux.com/puppy/viewtopic.php?p=180081]Pfilesearch[/url] package. Also remove file /root/.pfilesearch/pfilesearchrc if it exists.

Please give feedback if it works.

mikeb

It is nice to hear that you plan to works further on the verify-function. I will focus on another puppy project for some time, but I hope, that it will be time for looking at CD-text support.

To avoid the 'verify-button' after 'blanking disc' I just put

Code: Select all

export BURN_DATA=false
in the beginning of func_blanc.

Sigmund

User avatar
WhoDo
Posts: 4428
Joined: Wed 12 Jul 2006, 01:58
Location: Lake Macquarie NSW Australia

#159 Post by WhoDo »

zigbert wrote:Thank you guys for your bugreports. Try this new version uploaded. But before that, please install the newest Pfilesearch package. Also remove file /root/.pfilesearch/pfilesearchrc if it exists.
Please give feedback if it works.
Worked like a charm, Sigmund. Thanks. Now Puppy has a truly professional-look and -performing burning interface. Well done!
I can't wait until the world gets a really good look at the next generation of Puppy ... it'll knock their socks off, in large part due to your tireless efforts. Thank you, mate.
[i]Actions speak louder than words ... and they usually work when words don't![/i]
SIP:whodo@proxy01.sipphone.com; whodo@realsip.com

User avatar
mikeb
Posts: 11297
Joined: Thu 23 Nov 2006, 13:56

#160 Post by mikeb »

Hi Zigbert
To avoid the 'verify-button' after 'blanking disc' I just put
Code:
export BURN_DATA=false
in the beginning of func_blanc.
I was going to do this but in the scenerio of

launch pburn > blank disk > burn data disk

BURN_DATA will remain as false .
It is set to true initally but will only be set again if the 'burn data' radiobutton is pressed.. though the data burn still occurs by default (I thought it wouldn't!) the verify button (I am obsessed) will not show.

I afterwards also thought that the 'blank' flag could be used to disable the 'repeat burn' button if you see what I mean.

I have now gone crosseyed wih logic

have fun..it's the weekend :)

Mike

edit

if [[ $BURN_DATA = true && $BURN != "blank" ]]; then #verify button

double brackets for reliable intepretation

Post Reply