WizRemote - Set timers on your wiz remotely via the web!

Advanced Discussions on Programing for & Modifying Beyonwiz Products.

Moderators: Gully, peteru

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Thu Feb 07, 2008 11:22

GarFin wrote:EDIT: Or to put it another way... Has anyone successfully Telnet patched a (recent) P1 firmware yet ?
I have successfully modified the DPP1_Firmware_28Dec2007_ver_01.05.197.wrp firmware for my P1 for Telnet access...yes it works.
Thanks go to Eric :D
I'll put together a patch, similar to what Eric has released for the S1, but only for the 197 firmware at this stage.

User avatar
Kezza
Master
Posts: 465
Joined: Wed Aug 29, 2007 16:39
Location: Sydney

Post by Kezza » Thu Feb 07, 2008 11:55

can you do one for the S! as well please.

Kezza
? Kezza 2008

DLink Boxee Box
HD BW DP-S1 - Broken
SD Toppy 5000PVRt BP - Not Used
YAMAHA RXV800
B&W LM1
Harmony ONE Uni Remote
LG 47LY3DE LCD TV

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Thu Feb 07, 2008 12:58

Kezza wrote:can you do one for the S! as well please.
Seconded! :D

orangehenry
Apprentice
Posts: 14
Joined: Fri Nov 30, 2007 09:01

Post by orangehenry » Thu Feb 07, 2008 17:14

will this wizremote/telnet hack work with the dp-p1?

prl
Wizard God
Posts: 32703
Joined: Tue Sep 04, 2007 13:49
Location: Canberra; Black Mountain Tower transmitters

Post by prl » Thu Feb 07, 2008 17:16

alwayslooking posted that he had done the patch for the p1.
Peter
T4 HDMI
U4, T4, T3, T2, V2 test/development machines
Sony BDV-9200W HT system
LG OLED55C9PTA 55" OLED TV

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Thu Feb 07, 2008 17:55

Jammer wrote:
Kezza wrote:can you do one for the S! as well please.
Seconded! :D
How could I say 'no' to you guys :wink:
orangehenry wrote:will this wizremote/telnet hack work with the dp-p1?
Yes, as Ian posted, the hack will work on the P1, but you will have to use the patch that I'm about to release, not the one that Eric has done for the S1 on the earlier firmware.

As soon as I can confirm the patching process works successfully, I will post here with a link to DL from the Beyonwiz Software.

Note: Please thank Eric for doing all the hard work by exposing the hack.

janilxx

Post by janilxx » Thu Feb 07, 2008 18:25

prl wrote:alwayslooking posted that he had done the patch for the p1.
Could you please add all new telnet patches here: http://www.beyonwizsoftware.net/softwar ... e-patch/0/

Thanks!

janilxx

Post by janilxx » Thu Feb 07, 2008 19:01

Currently there is three persons who can edit this telnet patch message: I can edit all messages, Dave has updater rights and efry can edit his own message.

Everybody can become an updater, read more here: http://www.beyonwizsoftware.net/guides- ... d-more!/0/

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Thu Feb 07, 2008 20:29

janilxx wrote:
prl wrote:alwayslooking posted that he had done the patch for the p1.
Could you please add all new telnet patches here: http://www.beyonwizsoftware.net/softwar ... e-patch/0/

Thanks!
Sure, it'll probably be tomorrow when the wiz isn't doing any important stuff (like recording :wink:) and I can test everything.
Last edited by alwayslooking on Sat Feb 09, 2008 16:50, edited 2 times in total.

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Thu Feb 07, 2008 20:43

alwayslooking wrote:
Jammer wrote:
Kezza wrote:can you do one for the S! as well please.
Seconded! :D
How could I say 'no' to you guys :wink:
Thanks Matt. You rock, as usual!

j s
Master
Posts: 475
Joined: Thu Aug 30, 2007 19:40
Location: Geelong

Post by j s » Fri Feb 08, 2008 10:15

efry,


I can't get wizremote to start automtically after reboot

I've done this....

Code: Select all

# cat /tmp/config/rc.local
#!/bin/sh
# put this file in /tmp/config then reboot with wizremote.php to have wizremote start on boot
/bin/sleep 5
(cd /tmp/mnt/idehdd/wizremote; ./wizremote > /dev/null &)
...but to no avail. I still have to telnet in and start it manually, which also means it dies if I drop the telnet session.

Any suggestions?

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Fri Feb 08, 2008 12:05

j s wrote:efry,


I can't get wizremote to start automtically after reboot

I've done this....

Code: Select all

# cat /tmp/config/rc.local
#!/bin/sh
# put this file in /tmp/config then reboot with wizremote.php to have wizremote start on boot
/bin/sleep 5
(cd /tmp/mnt/idehdd/wizremote; ./wizremote > /dev/null &)
...but to no avail. I still have to telnet in and start it manually, which also means it dies if I drop the telnet session.

Any suggestions?
Hi J S,

Has the rc.local been saved to the flash. Also do you have the wizremote application in the /tmp/mnt/idehdd/wizremote/ directory?

Oh you also need to have execute permission on the rc.local file.

chmod 755 rc.local (or something similar)

So to reiterate

1. wizremote must be in /tmp/mnt/idehdd/wizremote/

2. rc.local must have execute permission

3. rc.local must have been saved to flash by rebooting the machine with the website. (or by running reboot.sh or cramfs_pref.sh)

I hope that helps. :)

j s
Master
Posts: 475
Joined: Thu Aug 30, 2007 19:40
Location: Geelong

Post by j s » Fri Feb 08, 2008 12:20

efry wrote: I hope that helps. :)
no :(
efry wrote: Has the rc.local been saved to the flash.
How do I confirm this? rc.local is still in /tmp/config after the reboot.
efry wrote: Also do you have the wizremote application in the /tmp/mnt/idehdd/wizremote/ directory?

Code: Select all

# ls -l /tmp/mnt/idehdd/wizremote
-rwxr-xr-x    1 0        0             181 Feb  7 15:13 rc.local
-rwxr-xr-x    1 0        0             555 Feb  6 05:39 reboot.sh
-rwxr-xr-x    1 0        0           66432 Feb  6 05:37 wizremote
-rwxr-xr-x    1 0        0              12 Feb  6 05:37 wizremote.key
efry wrote:

Oh you also need to have execute permission on the rc.local file.

chmod 755 rc.local (or something similar)

Code: Select all

# ls -l /tmp/config/rc.local
-rwxr-xr-x    1 0        0             181 Dec 31  1969 /tmp/config/rc.local
Actually, this might help....

Code: Select all

# ls -l
-rw-r--r--    1 0        0            1011 Dec 31  1969 book.xml
-rwxrwxrwx    1 0        0            3680 Dec 31  1969 fav.dat
-rw-rw-rw-    1 0        0             404 Dec 31  1969 favlist
-rw-r--r--    1 0        0             557 Dec 31  1969 iceCh
-rw-r--r--    1 0        0             557 Dec 31  1969 iceCh.bak
-rwx------    1 0        0             449 Dec 31  1969 iceDevList
-rw-r--r--    1 0        0            2190 Feb  7 17:09 main.conf
drwxrwxrwx    1 0        0               0 Dec 31  1969 network
drwxrwxrwx    1 0        0               0 Dec 31  1969 playlists
-rwxr-xr-x    1 0        0             181 Dec 31  1969 rc.local
-rw-rw-rw-    1 0        0              23 Feb  7 17:09 resolv.conf
-rw-rw-rw-    1 0        0            1412 Dec 31  1969 smbsnapshot.conf
-rwxrwxrwx    1 0        0            3199 Dec 31  1969 svc.dat
# ./rc.local
./rc.local: not found
Attempting to run rc.local manually produces "not found" though the ls shows it to exist.

prl
Wizard God
Posts: 32703
Joined: Tue Sep 04, 2007 13:49
Location: Canberra; Black Mountain Tower transmitters

Post by prl » Fri Feb 08, 2008 13:39

j s wrote:...
Actually, this might help....

Code: Select all

# ls -l
-rw-r--r--    1 0        0            1011 Dec 31  1969 book.xml
-rwxrwxrwx    1 0        0            3680 Dec 31  1969 fav.dat
-rw-rw-rw-    1 0        0             404 Dec 31  1969 favlist
-rw-r--r--    1 0        0             557 Dec 31  1969 iceCh
-rw-r--r--    1 0        0             557 Dec 31  1969 iceCh.bak
-rwx------    1 0        0             449 Dec 31  1969 iceDevList
-rw-r--r--    1 0        0            2190 Feb  7 17:09 main.conf
drwxrwxrwx    1 0        0               0 Dec 31  1969 network
drwxrwxrwx    1 0        0               0 Dec 31  1969 playlists
-rwxr-xr-x    1 0        0             181 Dec 31  1969 rc.local
-rw-rw-rw-    1 0        0              23 Feb  7 17:09 resolv.conf
-rw-rw-rw-    1 0        0            1412 Dec 31  1969 smbsnapshot.conf
-rwxrwxrwx    1 0        0            3199 Dec 31  1969 svc.dat
# ./rc.local
./rc.local: not found
Attempting to run rc.local manually produces "not found" though the ls shows it to exist.
Could the rc.local filename in /tmp/config have a funny character in its name (like being 'rc.local ')? Does

Code: Select all

cat ./rc.local
work?
Peter
T4 HDMI
U4, T4, T3, T2, V2 test/development machines
Sony BDV-9200W HT system
LG OLED55C9PTA 55" OLED TV

j s
Master
Posts: 475
Joined: Thu Aug 30, 2007 19:40
Location: Geelong

Post by j s » Fri Feb 08, 2008 14:38

prl wrote:Could the rc.local filename in /tmp/config have a funny character in its name (like being 'rc.local ')? Does

Code: Select all

cat ./rc.local
work?
Yes! My first post showed the output of a cat. Something wrong with the name occurred to me too.

Code: Select all

# cat ./rc.local
#!/bin/sh
# put this file in /tmp/config then reboot with wizremote.php to have wizremote start on boot
/bin/sleep 5
(cd /tmp/mnt/idehdd/wizremote; ./wizremote > /dev/null &)
It's all very puzzling :cry: the fle is there - but also not there. Like Schr?dinger's Cat. :roll:

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Fri Feb 08, 2008 15:37

j s wrote:
prl wrote:Could the rc.local filename in /tmp/config have a funny character in its name (like being 'rc.local ')? Does

Code: Select all

cat ./rc.local
work?
Yes! My first post showed the output of a cat. Something wrong with the name occurred to me too.

Code: Select all

# cat ./rc.local
#!/bin/sh
# put this file in /tmp/config then reboot with wizremote.php to have wizremote start on boot
/bin/sleep 5
(cd /tmp/mnt/idehdd/wizremote; ./wizremote > /dev/null &)
It's all very puzzling :cry: the fle is there - but also not there. Like Schr?dinger's Cat. :roll:
Is there anything before this line in the file?

Code: Select all

#!/bin/sh
It must be the first line with the # being the first character.

j s
Master
Posts: 475
Joined: Thu Aug 30, 2007 19:40
Location: Geelong

Post by j s » Fri Feb 08, 2008 16:02

efry wrote: Is there anything before this line in the file?

Code: Select all

#!/bin/sh
It must be the first line with the # being the first character.
That's the first line. Sent you a PM with details of another issue that could well be related.

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Sat Feb 09, 2008 16:54

janilxx wrote:
prl wrote:alwayslooking posted that he had done the patch for the p1.
Could you please add all new telnet patches here:
http://www.beyonwizsoftware.net/softwar ... e-patch/0/

Thanks!
alwayslooking wrote:Sure, it'll probably be tomorrow when the wiz isn't doing any important stuff (like recording :wink:) and I can test everything.
I've created a telnet patch for the P1here
It tested ok on my P1, I hope it works for you too.
Jammer wrote:
alwayslooking wrote:
Jammer wrote:
Kezza wrote:can you do one for the S! as well please.
Seconded! :D
How could I say 'no' to you guys :wink:
Thanks Matt. You rock, as usual!
I'll do the S1 01.05.197 telnet patch soon :wink:

I've got a working version of WizTools GUI, which makes doing this sort of thing a little easier. Once I sort a few of the niggles out I'll release that too (Dave, might need your help :) )

orangehenry
Apprentice
Posts: 14
Joined: Fri Nov 30, 2007 09:01

how to make server work

Post by orangehenry » Sat Feb 09, 2008 18:53

Hi, I'm really new to this whole server thing. So I've installed apache and php on an old computer i had lying around. I've got apache and php "working." I can get the phpinfo.php working properly in my web browser. However when i copy the files in the web folder into my htdocs folder and then surf to http://xxx.xxx.xxx.xxx/wizremote.php I get just a whole lot of code and not a web page.

What am I doing wrong? Are there any options/extension i specifcally need to change?

Thanks

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Sun Feb 10, 2008 15:07

I haven't setup the website yet, been too busy doing other things.
I'll have a look at how it is supposed to work and see why it might not be responding correctly.

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Sun Feb 10, 2008 17:28

OK, so I finally got around to setting up the wizremote, excellent work Eric :D

I didn't have any trouble getting it to run on IIS, but I'm getting a strange error with Monkey Web server on DSL:
Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /ramdisk/opt/monkey-0.9.1/htdocs/web/AES.class.php on line 12

I also am having some fun and games getting wizremote to start on reboot...and I have to telnet in to start it again.

EDIT: Nope, sorted it out and updated the howto.

I've put together what I did to set it up here

User avatar
DaveR
Wizard
Posts: 2527
Joined: Tue May 29, 2007 01:24
Location: Sydney

Post by DaveR » Sun Feb 10, 2008 22:34

Jammer wrote:
Kezza wrote:can you do one for the S! as well please.
Seconded! :D
Done. Matt was too slow :P

DP-S1 01.05.197 telnetd patch
http://www.beyonwizsoftware.net/softwar ... e-patch/0/
cheers
DaveR

IceTV, T4, T3, T2, P2, S1, FV-L1(P1 fw), TRF-2460, HDR-7500 and Skippa

orangehenry
Apprentice
Posts: 14
Joined: Fri Nov 30, 2007 09:01

thanks for the tutorial but...

Post by orangehenry » Sun Feb 10, 2008 23:00

Thanks for the tutorial - i finally got all the files on the dpp1 and my wizremote.php file showing up. however, when i go to login all i get is along laoding time and finally a blank page. I've followed the tutorial to a T. I've portforwarded 30464 to my dpp1.

Also, when i surf to wizremote.php i get the following

\n"; echo "\t\t$meta\n"; ?>
Login
Username: <?echo $userid; ?>
Password:

Login

Is that code meant to be there?
does anyone have any ideas as to whats going wrong?

thanks,

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Post by alwayslooking » Sun Feb 10, 2008 23:10

Dave? wrote:
Jammer wrote:
Kezza wrote:can you do one for the S! as well please.
Seconded! :D
Done. Matt was too slow :P

DP-S1 01.05.197 telnetd patch
http://www.beyonwizsoftware.net/softwar ... e-patch/0/
Yep...world domination and all that :lol:

Good on ya

User avatar
DaveR
Wizard
Posts: 2527
Joined: Tue May 29, 2007 01:24
Location: Sydney

Re: thanks for the tutorial but...

Post by DaveR » Mon Feb 11, 2008 00:01

orangehenry wrote:I've followed the tutorial to a T.
No wonder it's not working. Sorry, Matt, but as helpful as your tutorial was it was nowhere near complete (or more accurately it contained a lot of extra, incorrect, unneeded steps/commands).
cheers
DaveR

IceTV, T4, T3, T2, P2, S1, FV-L1(P1 fw), TRF-2460, HDR-7500 and Skippa

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Re: thanks for the tutorial but...

Post by tonymy01 » Mon Feb 11, 2008 00:13

orangehenry wrote: Is that code meant to be there?
does anyone have any ideas as to whats going wrong?
thanks,
Normally code in your webpage means you don't have PHP setup properly.
You have to enable the cgi options in whatever webserver you are running
(for lighttpd I have to enable these options for php in lighttpd.conf:
uncomment the "mod_fastcgi", server module, and enable the cgi options as such:

Code: Select all

#### fastcgi module
## read fastcgi.txt for more info
fastcgi.server             = ( ".php" =>
                               ( "localhost" =>
                                 (
                                   "socket" => "/tmp/php-fastcgi.socket",
                                   "bin-path" => "/opt/bin/php-fcgi",
                                   "max-procs" => 1,
                                   "bin-environment" =>
                                   (
                                      "PHP_FCGI_CHILDREN" => "2",
                                      "PHP_FCGI_MAX_REQUESTS" => "1000"
                                    )
                                 )
                               )
                            )
Regards
Tony

User avatar
alwayslooking
Master
Posts: 299
Joined: Tue Jul 03, 2007 10:56
Location: Adelaide
Contact:

Re: thanks for the tutorial but...

Post by alwayslooking » Mon Feb 11, 2008 10:22

Dave? wrote:
orangehenry wrote:I've followed the tutorial to a T.
No wonder it's not working. Sorry, Matt, but as helpful as your tutorial was it was nowhere near complete (or more accurately it contained a lot of extra, incorrect, unneeded steps/commands).
Sorry it is a work in progress... :wink:
I'll sort it out when as soon as I get a chance.

User avatar
peteru
Uber Wizard
Posts: 9735
Joined: Tue Jun 12, 2007 23:06
Location: Sydney, Australia
Contact:

Post by peteru » Mon Feb 11, 2008 18:53

Some servers require your CGI scripts to have the execute bit turned on.

Code: Select all

chmod a+x <scriptname>

"Beauty lies in the hands of the beer holder."
Blog.

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Tue Feb 12, 2008 07:45

Ok, I fixed an issue with Wizremote and IE.
It seems the code to call the authentication javascript doesn't kick in for IE, so you just get a blank page.
So you need to edit wizremote.php and change the following line:
<script language="javascript" src="validation.js" />
to
<script type="text/javascript" src="validation.js"></script>
and it all works perfectly.

Eric or a linux guru, how does rc.local manage to launch from /tmp/config? I can see there is a symbolic link to config from /etc, is this why/how?
I thought these types of launching scripts had to sit in /etc/init.d?
And well done on working out the Wiz tools to write the cram filesystem! I managed to finally understand the boot process through digging at various bits, and can see it copies the cramfs to /tmp/config with the bootcramfs app, but it must be the wizdvp app that updates the cramfs with any changed info in the ram mounted /tmp.

Oh, I spent some time trying to interpret svc.dat and have so far worked out that:
grr, the Wiz is little endian (or at least the long ints stored in svc.dat are). I have found it has BCD channel numbers (the RF frequency numbers) with their corresponding frequency in kHz:
0008 070100 89EC 0200 .... 02EC89= 191625kHz
0009 070100 6407 0300 ... 030764= 198500kHz
0010 070100 143E 0300 ... 033e14= 212500kHz
etc
But I can't find any of the TSIds or orignet IDs etc... well, I can (assuming little endedness) but they are usually not in any kind of order related to the channel names at the beginning of the list, or surrounded by their other IDs?...
I might have another poke at it today.

Regards
Tony

prl
Wizard God
Posts: 32703
Joined: Tue Sep 04, 2007 13:49
Location: Canberra; Black Mountain Tower transmitters

Post by prl » Tue Feb 12, 2008 08:29

tonymy01 wrote:...
Eric or a linux guru, how does rc.local manage to launch from /tmp/config? I can see there is a symbolic link to config from /etc, is this why/how?
I thought these types of launching scripts had to sit in /etc/init.d?
...
Linux guruhood (even if I were to claim it :)) doesn't really help here, because the /etc/inittab file for the ucLinux in the BW doesn't look much like a normal Linux inittab (syntax is the same, but the actions are very different), and so the normal assumptions about /etc/init.d and all the rc.runlevel directories don't hold..

It appears that /etc/config/rc.local is run from sys_up at boot time. sys_up has an explicit option, -r, that runs /etc/config/rc.local. As you saw, /etc/config is a symbolic link to /tmp/config, so the file actually run is /tmp/config/rc.local. sys_up isn't in fact run with that option anywhere in the rc.sysinit script (which is run by init from /etc/inittab), so I assume that it's also run by sys_up -b, but I haven't tried to trace the code to demonstrate that. There's also a call of sys_up -n (network setup) in rc.sysinit, but that's not run if BOOTMODE is NORMAL.

sys_up is run very early in the boot process, just after the flash ROMFS in the .wrp file (which contains the wizdvp application and so on) has been mounted, but before just about everything else. The flash ROMFS needs to be mounted, because /usr/local/bin/sys_up (on the root file system) is a symbolic link to /flash/bin/rompkg on the flash filesystem. /flash/bin/rompkg is a portmanteau program that, like busybox, implements several different commandline programs.

In case you're wondering, the root file system is packed away inside linux.bin.gz, and is resident in RAM when the system is running.
Peter
T4 HDMI
U4, T4, T3, T2, V2 test/development machines
Sony BDV-9200W HT system
LG OLED55C9PTA 55" OLED TV

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Tue Feb 12, 2008 08:58

Yep, already worked that bit out. I can even mount the various flash partitions and look at the filesystems on them. It took a few solid hours of understanding, but something I wanted to do as I want to pivot_root my ASUSWL600G (no openWRT for this one unfort, and very little tweaking out there, I managed to run one guys binaries to enable samba sharing of the HDD instead of stupidftpd) one day and so getting to understand a linux bootup completely is handy, even if the various filesystems are running from flash, or mounting from a gzipped file or whatever (I have my slug which definitely does do a pivot_root in the file /linuxrc).
I have also started looking at dump.dat (and sysconfig and bank0), and of course un-gzipped the guts of wizdvp to look a bit more into that (turns out ucLinux gzips its executable files after the header for V4 headers... this is perhaps what I unzipped when I looked for 0x1f8b in the Wiz wrp file a couple of months ago in an effort to unpackage it).
Regards
Tony

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Tue Feb 12, 2008 14:31

Oh, I spent some more time trying to interpret svc.dat and have so far worked out that:
vhfchan bw 0100? frequency orignetID TSid
11 07 0100 6C590300 1410 0206
12 07 0100 C4740300 1010 2102
28 07 0100 5C140800 0000 0000 (0000 means didn't scan anything which makes sense as VHF28 is SBS analogue).
All in little endian, so the VHF11 6C590300=0x03596c=219500kHz, 1410=0x1014=4116, 0x0602=1538 which are the origNetwork and TSIds for Ten
Similarly for VHF=ABC they all check out. These IDs don't change per RF mux, the svcIds are the unique entries per mux to map out to the channels.
Now to find exactly how to get svcIds matching the channel names earlier in the file (and match them to the list of scanned frequencies), and we should be able to avoid having to set these IDs in the wizremote app! I will look at this tonight, and hopefully will be able to hack something together to make this bit a lot simpler!

Edit:
Last piece of the puzzle found, LCNs and SVCIds found, now to try to get the toolchain working... or Eric, are you on this thread?

edit2:
Offset 0x30=Number of channel string entries
Offset 0x36=size of channel text string table
Offset 0x3E=beginning of string table
0x90BE delimiter? at end of string table.
offset of svcID count from the end of 0x90BE=4bytes. Offset from end of svcid cnt to beginning of SvcID table-0x58
SVCIDtable looks like:
(7 Digital=1312 SVCid=0x0520=2005 endian swapped)
SVCid_____probably_video/audioPIDS_______________________LCN___________________________
2005 0102 0202 0102 0100 0000 0000 0000 0000 0000 0400 0400 0700 0C00 0000 0103 0000 1002
So each record is 0x24bytes long
Cheers
Last edited by tonymy01 on Tue Feb 12, 2008 20:37, edited 2 times in total.
Tony

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Tue Feb 12, 2008 20:32

tonymy01 wrote:Oh, I spent some more time trying to interpret svc.dat and have so far worked out that:
vhfchan bw 0100? frequency orignetID TSid
11 07 0100 6C590300 1410 0206
12 07 0100 C4740300 1010 2102
28 07 0100 5C140800 0000 0000 (0000 means didn't scan anything which makes sense as VHF28 is SBS analogue).
All in little endian, so the VHF11 6C590300=0x03596c=219500kHz, 1410=0x1014=4116, 0x0602=1538 which are the origNetwork and TSIds for Ten
Similarly for VHF=ABC they all check out. These IDs don't change per RF mux, the svcIds are the unique entries per mux to map out to the channels.
Now to find exactly how to get svcIds matching the channel names earlier in the file (and match them to the list of scanned frequencies), and we should be able to avoid having to set these IDs in the wizremote app! I will look at this tonight, and hopefully will be able to hack something together to make this bit a lot simpler!

Edit:
Last piece of the puzzle found, LCNs and SVCIds found, now to try to get the toolchain working... or Eric, are you on this thread?

edit2:
Offset 0x30=Number of channel string entries
Offset 0x36=size of channel text string table
Offset 0x3E=beginning of string table
0x90BE delimiter? at end of string table.
offset of svcID count from the end of 0x90BE=4bytes. Offset from here to beginning of SvcID table-0x5a
SVCIDtable looks like:
(7 Digital=1312 SVCid=0x0520=2005 endian swapped)
SVCid_____probably_video/audioPIDS_______________________LCN___________________________
2005 0102 0202 0102 0100 0000 0000 0000 0000 0000 0400 0400 0700 0C00 0000 0103 0000 1002
So each record is 0x24bytes long
Cheers
Hey Tony,

Nice decoding.

I've also been looking at the svc data. I going to add a channel message to the wizremote app :)

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

wizremote 0.5

Post by efry » Tue Feb 12, 2008 20:38

Hi Guys,

I've updated the wizremote to version 0.5

Here's the change log and a download link.

Code: Select all

0.5 * Added HDD usage display.
      eg "HDD Used 51.78%, Total 297.97GB, Free 143.67GB"
    * Added  support for more characters types in the name field.
      You can now use ', & and " chars along with others.
    * Use the next start date when editing an existing timer.
    * Added tonymy01's fix for IE javascript.
http://www.beyonwizsoftware.net/softwar ... ;attach=33

Eric

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Tue Feb 12, 2008 20:51

Still decoding, I was editing when you posted. So can you code up the interpretation, and I guess we set timers with LCNs on the PHP side? It will probably take me a week to code something to parse the svc.dat file, esp with the endians screwed up (to me).
I actually think I got the offset of the svcId info out by a bit, but the size is right. If I work backwards from the 0x90BE at the end of the service table (normal HEX endian...) with the 0x24 times number of services, it takes me back to a little before where I said the services start.
Then the offset from the end of 0x90BE to the beginning of the RF channel info is
0x26bytes.
So the only thing I am missing is how to link the RF with the services... will edit this post in a few mins when i work it out :-)
Ok, this is a better serviceID record, at 0x50offset from the end of the servicecount.
I can see if you delete a channel, the text string dissapears, but the channel remains in the service list, and the 0x0103 is 0x0000 with a deleted channel.
0000 0103 0000 0002 2005 0102 0202 0102 0100 0000 0000 0000 0000 0000 0400 0400 0700 0000:- 2005=svcId 0700=LCN
0000 0103 0000 1002 2105 0102 0202 0102 0100 0000 0A00 0000 0000 0000 1900 1900 4700 0000:-2105=svcid 4700=LCN
Convert endedness before converting to decimal.

Yay, worked out the final piece in the jigsaw.
The third 2 byte integer in the 0x24byte service recording is the offset to RF channel 6 (well, offset to the table that follows the SVCId table really).
So my 7 records are (VHF6) 0000 0103 0000
vhf7
my 9 records are (VHF8) 0000 0103 0200
vhf9
vhf9a
vhf10
my 10records are (VHF11) 0000 0103 0600
etc

Regards
Tony

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Tue Feb 12, 2008 22:12

Hi Tony,

I've coded up a quick and dirty app to decode the svc.dat file
I haven't included your onid,tsid rf details yet.
At the moment it just prints the name and svcid

http://nuvie.sourceforge.net/temp/svc.c

I'll add the onid,tsid tomorrow and clean it up then move it into wizremote

Here's my svc.dat file

Code: Select all

7 Digital,1312
7 Digital 1,1313
7 Digital 2,1314
7 Digital 3,1315
7 HD Digital,1316
7 Guide,1318
NINE DIGITAL,1
NINE HD,5
NINE GUIDE,6
TEN HD,1569
TEN Digital,1573
TEN HD,1576
ABC HDTV,544
ABC TV Sydney,545
ABC2,546
ABC TV,547
ABC DiG Radio,550
ABC DiG Jazz,551
SBS HD,768
SBS,769
SBS NEWS,770
SBS 2,772
SBS RADIO 1,782
SBS RADIO 2,783

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Wed Feb 13, 2008 07:57

Guys, I've set up my web server, flashed the telnet 197 f/w to my S1 and can successfully telnet into the BW (using either putty or command-line telnet) , but can't do anything else whilst I'm in the BW i.e. create a new Wizremote directory, copy efry's files etc. Any suggestions? I was trying for hours last night and am a bit stumped at the moment. I've been using Matt's (alwayslooking) guide.

EDIT: I get no response when using the command "cd /tmp/mnt/idehdd/" and only get "md: not found" when trying to create the "wizremote" directory.

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Wed Feb 13, 2008 08:39

Linux is mkdir
are you putting a space after cd? Have you typed "ls or ls -al" and "pwd" to show the change directory actually did work?
Type mount, what do you see?
Type df, what do you see?
The HDD for me is exactly as effry said, in /tmp/mnt/idehdd

Code: Select all

# mount
/dev/root on / type romfs (ro)
none on /dev type devfs (rw)
/dev/blkmem/1 on /flash type romfs (ro)
proc on /proc type proc (rw)
usbfs on /proc/bus/usb type usbfs (rw)
ramfs on /tmp type ramfs (rw)
/dev/ide/host0/bus0/target0/lun0/part1 on /tmp/mnt/idehdd type vfat (rw,sync,nosuid)
//192.168.0.120/storedToppyCaptures on /tmp/mnt/smb/TONYSPC/storedToppyCaptures type smbfs (rw,nosuid,nodev,file_mode=0777,dir_mode=0777)

# df
Filesystem           1k-blocks      Used Available Use% Mounted on
/dev/root                15931     15931         0 100% /
/dev/blkmem/1             7575      7575         0 100% /flash
/dev/ide/host0/bus0/target0/lun0/part1195355136 101293568  94061568  52% /tmp/mnt/idehdd
//192.168.0.120/storedToppyCaptures312565760 232488960  80076800  74% /tmp/mnt/smb/TONYSPC/storedToppyCaptures

# cd /tmp/mnt/idehdd/
# ls -al
drwxr-xr-x    5 0        0          524288 Feb 12 02:25 .
drwxr-xr-x    1 0        0               0 Feb 11 09:13 ..
-rwxr-xr-x    1 0        0               0 Sep 22 06:30 .convtd
-rwxr-xr-x    1 0        0              75 Feb 12 02:25 .inrec
-rwxr-xr-x    1 0        0            4096 Sep 13 02:04 .super
-rwxr-xr-x    1 0        0              70 Feb 12 05:48 .tsbuf
drwxr-xr-x    3 0        0          524288 Sep 13 02:05 hyperspace
drwxr-xr-x   21 0        0          524288 Feb 12 08:02 recording
drwxr-xr-x    2 0        0          524288 Feb 12 04:38 wizremote

# pwd
/tmp/mnt/idehdd
#

Tony

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Wed Feb 13, 2008 09:12

efry wrote:Hi Tony,
I've coded up a quick and dirty app to decode the svc.dat file
I haven't included your onid,tsid rf details yet.
http://nuvie.sourceforge.net/temp/svc.c
Nice! I see you discovered one more thing than me (well 2 more, the offset of the text string in the service details being the other). I was wondering why there were some "phantom" channels at the end of the list that weren't included, and you worked out they are the mux names, well done!
So, do you want me to tweak svc.c with TS/ON stuff, or are you ok from here? (I always find it easier to code bits when someone else has done some of the coding, to see their techniques, as working from a clean slate I would have probably done it quite differently to what you did, defining structures with unknown longs etc and would have possibly taken a week to get right, but based on what you have done I think I can turn into code the bits I identified above).
Cheers
Tony

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Wed Feb 13, 2008 09:18

tonymy01 wrote:
efry wrote:Hi Tony,
I've coded up a quick and dirty app to decode the svc.dat file
I haven't included your onid,tsid rf details yet.
http://nuvie.sourceforge.net/temp/svc.c
Nice! I see you discovered one more thing than me (well 2 more, the offset of the text string in the service details being the other). I was wondering why there were some "phantom" channels at the end of the list that weren't included, and you worked out they are the mux names, well done!
So, do you want me to tweak svc.c with TS/ON stuff, or are you ok from here? (I always find it easier to code bits when someone else has done some of the coding, to see their techniques, as working from a clean slate I would have probably done it quite differently to what you did, defining structures with unknown longs etc and would have possibly taken a week to get right, but based on what you have done I think I can turn into code the bits I identified above).
Cheers
Hi Tony,

I've done a bit more work and I've got the onid and tsid fields in.

Here's my svc data.

Code: Select all

7 Digital,4115,1282,1312
7 Digital 1,4115,1282,1313
7 Digital 2,4115,1282,1314
7 Digital 3,4115,1282,1315
7 HD Digital,4115,1282,1316
7 Guide,4115,1282,1318
NINE DIGITAL,4114,1,1
NINE HD,4114,1,5
NINE GUIDE,4114,1,6
TEN HD,4116,1538,1569
TEN Digital,4116,1538,1573
TEN HD,4116,1538,1576
ABC HDTV,4112,545,544
ABC TV Sydney,4112,545,545
ABC2,4112,545,546
ABC TV,4112,545,547
ABC DiG Radio,4112,545,550
ABC DiG Jazz,4112,545,551
SBS HD,12802,768,768
SBS,12802,768,769
SBS NEWS,12802,768,770
SBS 2,12802,768,772
SBS RADIO 1,12802,768,782
SBS RADIO 2,12802,768,783
I'm working on moving it into wizremote now.

User avatar
tonymy01
Uber Wizard
Posts: 6373
Joined: Fri Jun 01, 2007 15:25
Location: Sydney, Australia DP-S1-1TB, DP-P2-2TB, DP-T4-2TB, DP-T4-BB... too many!
Contact:

Post by tonymy01 » Wed Feb 13, 2008 09:25

Too quick ;-)
I spent about 6 hours picking through svc.dat trying to understand exactly how it was assembled!
Well done again, you are an asset to the Topfield and Beyonwiz communities!
Tony

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Wed Feb 13, 2008 10:26

tonymy01 wrote:Linux is mkdir
are you putting a space after cd? Have you typed "ls or ls -al" and "pwd" to show the change directory actually did work?
Type mount, what do you see?
Type df, what do you see?
The HDD for me is exactly as effry said, in /tmp/mnt/idehdd
Thanks Tony. It's working now. Those commands got me on the right track. WizRemote is now running perfectly.

Huge thanks to Eric!

Just another thing: I noticed last night that my BW refused to open a telnet-patched firmware file with an altered background. Mind you, I had applied the telnet patch to a firmware that'd already had the background changed.....I haven't yet tried altering the background after the telnet patching to see if the BW will open the f/w. Anyone else experienced this?

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

wizremote v0.6

Post by efry » Wed Feb 13, 2008 15:28

Hi Guys,

I've updated wizremote to version 0.6

http://www.beyonwizsoftware.net/softwar ... ;attach=34

Code: Select all

0.6 * Added update_channels.php This script fetches the channel
      list array from the wiz. If config_channels_inc.php is
      writeable by your webserver it will be updated for you.
      If not then you will need to save the resulting the channel
      list file and copy it to your web directory manually.
    * Moved web config into config_inc.php
    * Moved channel array to config_channels_inc.php
    * Moved come common php functions into wizremote_inc.php
    * Added new chlist message to wizremote daemon. Thanks
      to tonymy01 for info on the svc.dat file
It should be much easier to get the channel data into wizremote.php now. :)


Eric

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Wed Feb 13, 2008 16:17

Great stuff Eric. Is file management possible? i.e. deleting, renaming recordings etc

janilxx

Post by janilxx » Wed Feb 13, 2008 16:31

What kind of interface is this unofficial timer interface?
I mean if I will create Java application, can I use this interface? Sockets, HTTP and so on can be coded with Java.

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Wed Feb 13, 2008 16:40

Jammer wrote:Great stuff Eric. Is file management possible? i.e. deleting, renaming recordings etc
Hi Jammer,

Not at the moment. You can currently add,edit or delete timers.

I don't think it would be too hard to add file management functions in the future. :)

Eric

efry
Master
Posts: 150
Joined: Thu Aug 30, 2007 22:01
Location: Sydney
Contact:

Post by efry » Wed Feb 13, 2008 16:45

janilxx wrote:What kind of interface is this unofficial timer interface?
I mean if I will create Java application, can I use this interface? Sockets, HTTP and so on can be coded with Java.
Hi Janilxx,

It's shouldn't be hard to code it up in java. The interface is very simple. You'll just need an AES implementation for java to do the initial handshake.

The rest is ascii text based over standard sockets.

Eric

User avatar
Jammer
Master
Posts: 320
Joined: Thu Aug 30, 2007 12:56
Location: Gold Coast, Australia

Post by Jammer » Wed Feb 13, 2008 16:48

efry wrote:
Jammer wrote:Great stuff Eric. Is file management possible? i.e. deleting, renaming recordings etc
Hi Jammer,

Not at the moment. You can currently add,edit or delete timers.

I don't think it would be too hard to add file management functions in the future. :)

Eric
Sorry Eric, I wasn't clear at all with that question :oops:. I know that file management isn't currently possible and was seeking clarification re. if it'd be something that should be relatively easy to implement, now that you're really getting "under the hood". But you pretty much answered my question.

j s
Master
Posts: 475
Joined: Thu Aug 30, 2007 19:40
Location: Geelong

Post by j s » Wed Feb 13, 2008 20:24

Here's a teaser of WizWeb (aka ToppyWeb and PVRweb) - still a bit of work to go - no actions implemented yet but that should be easier.

For those not familiar with ToppyWeb you can see how it works on the Demonstration website (the userid/password is toppyweb/demo).

Beyonwiz support will be integrated into the same structure.

Image


Image
Last edited by j s on Wed Feb 13, 2008 21:16, edited 2 times in total.

Post Reply

Return to “Software Developers”