Rockbox Technical Forums

Support and General Use => Theming and Appearance Customization => Topic started by: magnumforce2006 on March 01, 2008, 02:49:20 AM

Title: --debugwps in simulator
Post by: magnumforce2006 on March 01, 2008, 02:49:20 AM
I'm obviously missing something huge here... I downloaded a new simulator to attempt to fix an older (custom) WPS of mine and I have... No idea how to execute "--debugwps" that I've been reading about.

What exactly needs to be done to do this?
Title: Re: --debugwps in simulator
Post by: RedBreva on March 01, 2008, 02:54:38 AM
Within Windows, I created a new debug.bat file containing:

Code: [Select]
del Debugwps.txt /F
rockboxui.exe --background --debugwps > Debugwps.txt 2>&1

When you run the sim with this bat file, the output is diverted to a Debugwps.txt file (in the sim folder) and you can then read it looking to find the error line...
Title: Re: --debugwps in simulator
Post by: magnumforce2006 on March 01, 2008, 03:01:32 AM
Hm, thank you. Now we're getting somewhere.

Now

Code: [Select]
settings_reset()
reload_all_settings()
We open the real file 'archos/.rockbox/nvram.bin'
We open the real file 'archos/.rockbox/config.cfg'
We open the real file 'archos/.rockbox/nvram.bin'
We open the real file 'archos/.rockbox/config.cfg'
We open the real file 'archos/.rockbox/fixed.cfg'
settings_apply()
We open the real file 'archos/.rockbox/wps/ipodVision_5g-Art_planetary.wps'
[  0] = (56) progressbar bitmap
[  1] = ( 3) String '    '
[  2] = (69) track number
[  3] = ( 3) String ' ('
[  4] = (86) position in playlist
[  5] = ( 3) String '/'
[  6] = (84) number of entries in playlist
[  7] = ( 3) String ') '
[  8] = ( 6) align right
[  9] = (25) rtc: hour ( 1..12)
[ 10] = ( 3) String ':'
[ 11] = (27) rtc: minute (00..59)
[ 12] = ( 7) left margin, value: 112
[ 13] = ( 3) String '310'

Number of string tokens: 6

Strings:
 0: ( 4) '    '
 1: ( 2) ' ('
 2: ( 1) '/'
 3: ( 2) ') '
 4: ( 1) ':'
 5: ( 3) '310'

Number of unique strings: 6 (max: 128)
Total string length: 13
String buffer used: 19 out of 1024 bytes

Number of lines   : 4
Number of sublines: 4
Number of tokens  : 14

Line  0 (num_sublines=1, first_subline=0)
    Subline 0: first_token=  0, last_token=  0
Line  1 (num_sublines=1, first_subline=1)
    Subline 0: first_token=  1, last_token=  0
Line  2 (num_sublines=1, first_subline=2)
    Subline 0: first_token=  1, last_token= 11
Line  3 (num_sublines=1, first_subline=3)
    Subline 0: first_token= 12, last_token= 13

Failed parsing on line 36 : unexpected conditional char after token 13: "String '310'"
We open the real file 'archos/.rockbox/backdrops/ipodVision_5g_planetary.bmp'
totalsize: 153600
We open the real file 'archos/.rockbox/fonts/helvB12-L1.fnt'
We open the real file 'archos/.rockbox/icons/tango_small.bmp'
totalsize: 9216
We open the real file 'archos/.rockbox/icons/tango_small_viewers.bmp'
totalsize: 3168
We open the real file 'archos/.rockbox/icons/tango_small_viewers.icons'
We open the real file 'archos/.rockbox/themes/-.colours'
We open the real file 'archos/.rockbox/database_tmp.tcd'
We open the real file 'archos/.rockbox/tagnavi.config'
We open the real file 'archos/.rockbox/tagnavi_custom.config'
We open the real file 'archos/.rockbox/viewers.config'
We open the real file 'archos/.rockbox/icons/tango_small_viewers.icons'
We open the real file 'archos/.rockbox/themes/-.colours'
We open the real file 'archos/.rockbox/langs/english.voice'
We open the real file 'archos/.rockbox/database_idx.tcd'
We open the real file 'archos/.rockbox/nvram.bin'
We open the real file 'archos/.rockbox/.playlist_control'
Adding Falling Cycle - Alone.mp3
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/nvram.bin'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/.rockbox/nvram.bin'
[  0] = (38) conditional, 2 options
[  1] = (70) track title
[  2] = (39) conditional start, next cond: 11
[  3] = (38) conditional, 2 options
[  4] = (69) track number
[  5] = (39) conditional start, next cond: 8
[  6] = (69) track number
[  7] = ( 3) String '. '
[  8] = (40) conditional option, next cond: 9
[  9] = (41) conditional end
[ 10] = (70) track title
[ 11] = (40) conditional option, next cond: 13
[ 12] = (49) file name
[ 13] = (41) conditional end
[ 14] = (38) conditional, 2 options
[ 15] = (62) track artist
[ 16] = (39) conditional start, next cond: 18
[ 17] = (62) track artist
[ 18] = (40) conditional option, next cond: 26
[ 19] = (38) conditional, 2 options
[ 20] = (54) file directory, level: 2
[ 21] = (39) conditional start, next cond: 23
[ 22] = (54) file directory, level: 2
[ 23] = (40) conditional option, next cond: 25
[ 24] = ( 3) String '(root)'
[ 25] = (41) conditional end
[ 26] = (41) conditional end
[ 27] = (38) conditional, 2 options
[ 28] = (66) track album
[ 29] = (39) conditional start, next cond: 31
[ 30] = (66) track album
[ 31] = (40) conditional option, next cond: 39
[ 32] = (38) conditional, 2 options
[ 33] = (54) file directory, level: 1
[ 34] = (39) conditional start, next cond: 36
[ 35] = (54) file directory, level: 1
[ 36] = (40) conditional option, next cond: 38
[ 37] = ( 3) String '(root)'
[ 38] = (41) conditional end
[ 39] = (41) conditional end
[ 40] = ( 3) String ' '
[ 41] = (38) conditional, 2 options
[ 42] = (72) track year
[ 43] = (39) conditional start, next cond: 47
[ 44] = ( 3) String '('
[ 45] = (72) track year
[ 46] = ( 3) String ')'
[ 47] = (40) conditional option, next cond: 48
[ 48] = (41) conditional end
[ 49] = ( 4) align left
[ 50] = (81) time elapsed in track
[ 51] = ( 3) String '/'
[ 52] = (83) track length
[ 53] = ( 6) align right
[ 54] = ( 3) String '['
[ 55] = (86) position in playlist
[ 56] = ( 3) String ':'
[ 57] = (84) number of entries in playlist
[ 58] = ( 3) String ']'
[ 59] = (45) file bitrate
[ 60] = ( 3) String 'kBit '
[ 61] = (38) conditional, 2 options
[ 62] = (53) file is vbr
[ 63] = (39) conditional start, next cond: 65
[ 64] = ( 3) String 'avg'
[ 65] = (40) conditional option, next cond: 66
[ 66] = (41) conditional end
[ 67] = ( 3) String ' '
[ 68] = (38) conditional, 2 options
[ 69] = (71) track ID3 version
[ 70] = (39) conditional start, next cond: 74
[ 71] = ( 3) String '(id3v'
[ 72] = (71) track ID3 version
[ 73] = ( 3) String ')'
[ 74] = (40) conditional option, next cond: 76
[ 75] = ( 3) String '(no id3)'
[ 76] = (41) conditional end
[ 77] = (77) progressbar
[ 78] = (78) peakmeter

Number of string tokens: 16

Strings:
 0: ( 2) '. '
 1: ( 6) '(root)'
 2: ( 1) ' '
 3: ( 1) '('
 4: ( 1) ')'
 5: ( 1) '/'
 6: ( 1) '['
 7: ( 1) ':'
 8: ( 1) ']'
 9: ( 5) 'kBit '
10: ( 3) 'avg'
11: ( 5) '(id3v'
12: ( 8) '(no id3)'

Number of unique strings: 13 (max: 128)
Total string length: 36
String buffer used: 49 out of 1024 bytes

Number of lines   : 8
Number of sublines: 8
Number of tokens  : 79

Line  0 (num_sublines=1, first_subline=0)
    Subline 0: first_token=  0, last_token= 13, scrolled
Line  1 (num_sublines=1, first_subline=1)
    Subline 0: first_token= 14, last_token= 26, scrolled
Line  2 (num_sublines=1, first_subline=2)
    Subline 0: first_token= 27, last_token= 48, scrolled
Line  3 (num_sublines=1, first_subline=3)
    Subline 0: first_token= 49, last_token= 48
Line  4 (num_sublines=1, first_subline=4)
    Subline 0: first_token= 49, last_token= 58
Line  5 (num_sublines=1, first_subline=5)
    Subline 0: first_token= 59, last_token= 76
Line  6 (num_sublines=1, first_subline=6)
    Subline 0: first_token= 77, last_token= 77, progressbar
Line  7 (num_sublines=1, first_subline=7)
    Subline 0: first_token= 78, last_token= 78, peakmeter

We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/.rockbox/codecs/mpa.codec'
failed to load archos/_temp_codec0.dll
dlopen(archos/_temp_codec0.dll): »@‘|ŽÖ
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chUsing background image.
WPS debug mode enabled.
Mouse at: (186, 87)
mode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/Falling Cycle - Alone.mp3'
Header: fffb920c, Ver 0, lay 3, bitr 128, freq 44100, chmode 0, mode_ext 0, emph 0, bytes: 418 time: 1280/49
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'
We open the real file 'archos/.rockbox/codecs/mpa.codec'
We open the real file 'archos/Falling Cycle - Alone.mp3'

What am I looking for here?
Title: Re: --debugwps in simulator
Post by: pixelma on March 01, 2008, 03:58:08 AM
Code: [Select]
Failed parsing on line 36 : unexpected conditional char after token 13: "String '310'"You're looking for an additional character that is typically used in conditionals, so '<' , '>' or '|' on line 36.

Probably there is either a conditional that has one '>' too many, or - and that seems a common mistake - one of these three should just be displayed as character, outside a conditional, but are not "escaped". You would have to prepend a '%' to have one of these displayed; this is explained in the CustomWPS wiki page.

I believe parsing stops after the first error it finds, so maybe fixing this will reveal some more in lines below.
Title: Re: --debugwps in simulator
Post by: magnumforce2006 on March 01, 2008, 04:47:24 AM
Aha, thank you everyone. After a lot of playing around with the .wps file I finally did get it all to work and, to my surprise, the margins worked perfectly with the newer offifical builds.

There's just a minor problem that remains with the bottom of album artwork being cutoff, but I think I'll tackle that at another date, as I'm rather tired, haha.