PDA

View Full Version : Syntax of Commandline Options in dongle.bin.config



jksmurf
2007-05-15, 03:50 PM
OK, now that my dongle.bin.config works. .. :-)

http://mvpmc.wikispaces.com/commandline has a list of Syntax of Commandline Options.

1. What is the Syntax of these commands?
e.g. I have

mvpmc --startup emulate --emulate 192.168.1.10 &
If I want to force:
(a) pal AND (b)svideo AND (c) and 4:3 AND (d)SPDIF (passthru) can I do BOTH Svideo AND passthru? The web site above seems to suggest "Enumerated arguments, where you must supply one of the listed choices, are shown separated by a vertical bar (composite | svideo | stereo | passthru). "

i.e. will

mvpmc options -m pal -a 4:3 -o svideo -o passthru work

2. Do I add these on one or seperate lines? Is there an ORDER of loading?


mvpmc options -m pal -a 4:3 -o svideo -o passthru --startup emulate --emulate 192.168.1.10 &

OR



mvpmc --startup emulate --emulate 192.168.1.10 &
mvpmc options -m pal -a 4:3 -o svideo -o passthru

3. How do I add a Comment? "rem" or ";" or "!" or sth else?

Cheers

k.

OscarL
2007-05-15, 04:21 PM
Hi Martin,
On the subject of syntax, I was not able to get the config file working that you suggested some time ago.
I could only test it shortly before leaving for a business trip but it always hanged during the reading of the file.
You suggested this:

if [ $IP="192.18.1.1" ] ; then
mvpmc options -o svideo
else
mvpmc options -o composite
fi


Is there some obvious error there or is something missing.

Regards
Oscar

mvallevand
2007-05-15, 04:42 PM
I'll update this after work but here's some quick info

dongle.bin.config is actually just a linux bash script so if you want to get fancy there's plenty of info on this on the internet.

Some notes.

1. Self-explanatory I think

# This line is a comment.

2. the command line options are all on one line following mvpmc but you can use the back slash \ as as continuation character

3. when I use options that is not part of the syntax that is something that you should replace with your command line options.

4. order isn't important

5. you can have multiple -o 's


Martin

mvallevand
2007-05-16, 12:08 AM
To set the default volume you need a special config file on your remote mvpmc volume. It will need read/write to save your options the first time.

1. Here are the script changes

umount /etc/mvpmc
mount.cifs //$IP/mvpmc /etc/mvpmc -o username=guest,password=guest,rw

2. Then you need this on the command line

-F /etc/mvpmc/defaults

3. When you have the volume you like for Emulation Mode Go Back to the Main Menu and in the Setup option on the main menu click on Save Settings.

Martin

jksmurf
2007-05-16, 12:42 AM
Timely post Martin, my default Volume is actually a bit too low and even usign Volume up (which works with MVPMC, one of my BIG reasons to use that dongle).

I used your dongle last night and it works so well, I'm going to leave it in the MVP. I took all the previous ones out, but the auto-start and its stability is real clincher.

wrt your above volume post, I take it:

(1) is issued via telnet again and
(2) is added to my command line (anywhere after mvpmv?)

e.g.



mvpmc -F /etc/mvpmc/defaults options -m pal -a 4:3 -o svideo -o passthru --startup emulate --emulate 192.168.1.10 &

At this juncture I have to say a little "wo" (as this is getting a bit beyond my feeble brain). The commandline options clearly give you incredible power and flexibility, but at some stage a frontend or browser selection would lend itself well to the ordinary user (which I'm not far off being tbh). A bit like Zehd Process or GUI4FFMEPG for ffmepg. Is this one of the future aims of this testing?

The commandline page (http://mvpmc.wikispaces.com/commandline) notes:

There are two other ways to configure: via the web interface (http://mvpmc.wikispaces.com/webinterface) or via the menus (http://mvpmc.wikispaces.com/menus.settings).

1. So I guess I have to ask, is the web-interface ready for prime-time?

I guess what I'd quite like to see is drop down options for each switch, so I can choose svideo, 4:3, pal, passthru, default volume, WOL etc. etc. a bit like in EWA I guess. Any chance of that :)

2. What does flicker mode do? (I searched the mvpmc site FAQ, but no joy there). I "believe" I noticed a bit of extra flicker with the mvpmc dongle, although this might just be brightness cause by my (now) forcing svideo rather than composite.

k.

mvallevand
2007-05-16, 01:14 AM
Timely post Martin, my default Volume is actually a bit too low and even usign Volume up (which works with MVPMC, one of my BIG reasons to use that dongle).

I used your dongle last night and it works so well, I'm going to leave it in the MVP. I took all the previous ones out, but the auto-start and its stability is real clincher.

I'm glad its starting to get better for you.




wrt your above volume post, I take it:

(1) is issued via telnet again and
(2) is added to my command line (anywhere after mvpmv?)



The lines in 1 actually get added to the dongle.bin.config script but yes you add the -F etc to the command line. The word options is not necessary.

Also now using the -F you can set pal, 4:3, svideo and passtru via the setup option so they don't need to be on the command line.




At this juncture I have to say a little "wo" (as this is getting a bit beyond my feeble brain). The commandline options clearly give you incredible power and flexibility, but at some stage a frontend or


I agree 100% but I can't get the other dev's to buy-in to other options like the browser interface. As a result there is not one place to configure mvpmc



I guess what I'd quite like to see is drop down options for each switch, so I can choose svideo, 4:3, pal, passthru, default volume, WOL etc. etc. a bit like in EWA I guess. Any chance of that :)


Me too. I just don't like the looks of what I've designed so far. Someone started working on something based on freenas http://www.freenas.org/index.php?option=com_content&task=view&id=15&Itemid=28
which I though would be cool but didn't have the time. I'm still looking for someone to help redesign the pages (without javascript or php).

What's there now works and could even be made to load via the config script too but I don't think it's complete enough to bother.




2. What does flicker mode do? (I searched the mvpmc site FAQ, but no joy there). I "believe" I noticed a bit of extra flicker with the mvpmc dongle, although this might just be brightness cause by my (now) forcing svideo rather than composite.

k.

I hasn't done anything before the alpha, but right now it might do what the Hauppauge dongle does from 0 no flicker to 2 full flicker. I don't have a tv that flickers to test. If you've got a flicker setting in flash it will use that too.

Martin

jksmurf
2007-05-16, 01:59 AM
The lines in 1 actually get added to the dongle.bin.config script but yes you add the -F etc to the command line. The word options is not necessary.

So the steps are:

A. FIRST (my) dongle.bin.config script would read:



umount /etc/mvpmc
mount.cifs //$IP/mvpmc /etc/mvpmc -o username=guest,password=guest,rw


B. Reboot MVPMC. When MVPMC starts, I then choose a Volume I like and go back to the Main Menu and in the Setup option on the main menu click on "Save Settings".


Also now using the -F you can set pal, 4:3, svideo and passtru via the setup option so they don't need to be on the command line.

C. I then REDO my dongle.bin.config with the commandline script (w/o options, -m pal -a 4:3 -o svideo -o passthru)



mvpmc -F /etc/mvpmc/defaults --startup emulate --emulate 192.168.1.10 &


I agree 100% but I can't get the other dev's to buy-in to other options like the browser interface. As a result there is not one place to configure mvpmcOh that's a real bummer. IMHO this will never get the mainstream exposure it deserves without it.


Me too. I just don't like the looks of what I've designed so far. Someone started working on something based on freenas http://www.freenas.org/index.php?option=com_content&task=view&id=15&Itemid=28
which I though would be cool but didn't have the time. I'm still looking for someone to help redesign the pages (without javascript or php). That's a nice interface ...


What's there now works and could even be made to load via the config script too but I don't think it's complete enough to bother.Yeah, sorry to say it's a little "messy" :o for me, btw the "reboot button" is in the RADIO section which might confuse some folks. Might want a seperate section for that? (it's another PLUS of mvpmc...).


I hasn't done anything before the alpha, but right now it might do what the Hauppauge dongle does from 0 no flicker to 2 full flicker. I don't have a tv that flickers to test. If you've got a flicker setting in flash it will use that too.So if I have flickering I choose 0? Why would one choose 1 or 2?

You often refer to flash, how do I access the flash, only via the Hauppauge dongle and interface? I hate loading that thing onto my PC ...

Thanks, this is so great!

k.

mvallevand
2007-05-16, 02:46 AM
A. FIRST (my) dongle.bin.config script would read:


To avoid rebooting I suggest this dongle.bin.config



umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=guest,password=guest,rw
mvpmc -F /etc/mvpmc/defaults --startup emulate --emulate 192.168.1.10 &





Oh that's a real bummer. IMHO this will never get the mainstream exposure it deserves without it.


It's difficult since most people just want a more stable Hauppauge dongle. It pains me to see people reverting to old versions of GBPVR rather the diagnosing their real problems. Really,I don't think browser configuration would make much difference because the normal response with a bad experience with emulation mode is going to be to give up. People forget how often they see the MediaMVP blue screen, the Connecting to servers, failure to connect to GUI etc. I actually became so used to unplugging the mvp to load the dongle, it became second nature. Plus during the first 5 minutes you aren't going to see any benefits to mvpmc so its not an easy alternative to sell to the better half.




Yeah, sorry to say it's a little "messy" :o for me, btw the "reboot button" is in the RADIO section which might confuse some folks. Might want a seperate section for that? (it's another PLUS of mvpmc...).


Thats my fault. I've got an mvp hooked up to some old computer speakers with no TV, that I use solely for listening to internet radio while I do some exercising. It made sense at the time since it really was just for me but the plugin redesign will make this all more logical.



So if I have flickering I choose 0? Why would one choose 1 or 2?


No the opposite 0 is no flicker problems, 2 would be worst case flicker in theory



You often refer to flash, how do I access the flash, only via the Hauppauge dongle and interface? I hate loading that thing onto my PC ...


Yes flash access is through Hauppague dongle and their server Setup.

Martin

jksmurf
2007-05-16, 03:47 AM
To avoid rebooting I suggest this dongle.bin.config



umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=guest,password=guest,rw
mvpmc -F /etc/mvpmc/defaults --startup emulate --emulate 192.168.1.10 &


Yeah but if it AUTO-starts into emulation mode ... how on earth do I get to the SETTINGS screen :confused: to set the default volume and other params initially?


It's difficult since most people just want a more stable Hauppauge dongle. It pains me to see people reverting to old versions of GBPVR rather the diagnosing their real problems. Really,I don't think browser configuration would make much difference because the normal response with a bad experience with emulation mode is going to be to give up. People forget how often they see the MediaMVP blue screen, the Connecting to servers, failure to connect to GUI etc. I actually became so used to unplugging the mvp to load the dongle, it became second nature. Plus during the first 5 minutes you aren't going to see any benefits to mvpmc so its not an easy alternative to sell to the better half.I agree with your first part, but still believe many folks stay away if they are not used to commandline type things.... stuff they can TRY out with no real issues ... be pointed to....posted pics of...


Yes flash access is through Hauppauge dongle and their server Setup. MartinI suppose there is no way you can do this too :-)

k.

mvallevand
2007-05-16, 04:25 AM
Yeah but if it AUTO-starts into emulation mode ... how on earth do I get to the SETTINGS screen :confused: to set the default volume and other params initially?

Hit the Go key then the Back key


I agree with your first part, but still believe many folks stay away if they are not used to commandline type things.... stuff they can TRY out with no real issues ... be pointed to....posted pics of...

I don't disagree that it is needed, and I figure a client side VB or Java program that created a config script could be written in an afternoon. There haven't been any volunteers on the mvpmc side maybe one day someone will like emulation mode enough to do it here?


I suppose there is no way you can do this too :-)


A few people on the team, especially Jon the project leader could write the code to write to flash, and I've talked to Hauppauge to discuss how it could be done without touching their setting. I've even stored mvpmc completely to flash and believe me it's cool. The problem is how many people do you think are willing to test this and risk bricking their machines?

Martin

pz1
2007-05-16, 05:05 AM
I hasn't done anything before the alpha, but right now it might do what the Hauppauge dongle does from 0 no flicker to 2 full flicker. I don't have a tv that flickers to test. If you've got a flicker setting in flash it will use that too.
Martin
Martin, you may recall that I was the first to complain about flicker. You changed a bit, but as I reported that did not change much. The best place to see flicker is on the horizontal lines of the program guide. Later I looked at that with the standard hauppauge dongle. I saw only very little difference with the three possible settings.
pieter

mvallevand
2007-05-16, 11:53 AM
Martin, you may recall that I was the first to complain about flicker. You changed a bit, but as I reported that did not change much. The best place to see flicker is on the horizontal lines of the program guide. Later I looked at that with the standard hauppauge dongle. I saw only very little difference with the three possible settings.
pieter

Pieter I do recall, and I've asked Hauppauge for more info, right now I just don't have enough knowledge to help and I'm not even sure if flicker is the only problem. The Sudoku plugin for me is really difficult to watch on the Hauppauge dongle on any flicker setting.

Martin

jksmurf
2007-05-19, 01:07 AM
To avoid rebooting I suggest this dongle.bin.config


umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=guest,password=guest,rw
mvpmc -F /etc/mvpmc/defaults --startup emulate --emulate 192.168.1.10 &



Martin, Syntax Q again:

If I wanted to (a) set SPDIF always on and (b) Set flicker to 2 would a change of the code above to this be correct?



umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=guest,password=guest,rw
mvpmc -F /etc/mvpmc/defaults -o passthru --flicker 2 --startup emulate --emulate 192.168.1.10 &


I think I mentioned before, PAL and Svideo are already saved (presumably by a previous Hauppage Dongle Flash (wow I am finally getting the hang this....:rolleyes: ) but SPDIF is not and choosing flicker is not even an option. I am never sure when I hit "GO BACK" into settings, whether it really WAS in SPDIF mode before, as it always reverts to stereo; I guess it's just unnerving not knowing ... :o

k.

mvallevand
2007-05-19, 01:34 AM
mvpmc -F /etc/mvpmc/defaults -o passthru --flicker 2 --startup emulate --emulate 192.168.1.10 &

That will work.



I think I mentioned before, PAL and Svideo are already saved (presumably by a previous Hauppage Dongle Flash (wow I am finally getting the hang this....:rolleyes: ) but SPDIF is not and choosing flicker is not even an option. I am never sure when I hit "GO BACK" into settings, whether it really WAS in SPDIF mode before, as it always reverts to stereo; I guess it's just unnerving not knowing ... :o

Remember when you set the setting in the main menu, you have to click save settings, same as with the volume change. You will know it works because you will have a file called defaults in you mvpmc folder.

Martin

jksmurf
2007-05-19, 01:42 AM
Remember when you set the setting in the main menu, you have to click save settings, same as with the volume change. You will know it works because you will have a file called defaults in your mvpmc folder. Martin

Oh dear. :o Is there a "I'm a big dummy" icon in here, LOL. I'll try that ... thanks!

k.

jksmurf
2007-05-19, 06:06 AM
Remember when you set the setting in the main menu, you have to click save settings, same as with the volume change. You will know it works because you will have a file called defaults in you mvpmc folder. Martin

I get an error message "Config file save failed"
I have it C:\Program Files\devnz\gbpvr\Dongle\mvpmc
It made a defaults file after I checked "allow networks users to change my files" but it's a 0 byte file and it still gives the error message...:confused: ...

k.

mvallevand
2007-05-19, 11:58 AM
I get an error message "Config file save failed"
I have it C:\Program Files\devnz\gbpvr\Dongle\mvpmc
It made a defaults file after I checked "allow networks users to change my files" but it's a 0 byte file and it still gives the error message...:confused: ...

k.

k, I'm confused too. Definitely you don't need to create the file yourself, I suggest trying again maybe you will have another Bobins moment. If not telnet to your box and issue this

killall mvpmc
mvpmc -F /etc/mvpmc/defaults -o passthru --flicker 2

and try and do your save if it fails there should be an error message on your telnet screen



Martin

jksmurf
2007-05-20, 05:55 AM
k, I'm confused too. Definitely you don't need to create the file yourself, I suggest trying again maybe you will have another Bobins moment. If not telnet to your box and issue this


killall mvpmc
mvpmc -F /etc/mvpmc/defaults -o passthru --flicker 2

and try and do your save if it fails there should be an error message on your telnet screen
Martin

Martin,

Actually I never created that (0-byte) file myself tbh, it was created by the save (even though error message was there!) after I set the mvpmc share to "allow network users to change my files" (Is this correct btw?)

Telnet result attached. Error 195?

In any case the other way to make it default to SPDIF is just to stick it all on the command line as follows I guess. That works.


umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=guest,password=guest,rw
mvpmc -F /etc/mvpmc/defaults -o passthru --flicker 2 --startup emulate --emulate 192.168.1.10 &

Still wonder why it won't save config though. Share Path is C:\Program Files\devnz\gbpvr\Dongle\mvpmc presumably no problem with that?

HtV the Routers are 3m above each other vertically.... :-)
k.

HtV
2007-05-20, 09:09 AM
HtV the Routers are 3m above each other vertically.... :-)


With a floor in the middle I guess.:) However if it's a concrete floor with alot of steel in it you would loose alot of bandwith I guess. Did you check the connection with a laptop or something?

mvallevand
2007-05-20, 02:11 PM
Martin,

Actually I never created that (0-byte) file myself tbh, it was created by the save (even though error message was there!) after I set the mvpmc share to "allow network users to change my files" (Is this correct btw?)

Telnet result attached. Error 195?

Thanks a lot. That shows the line number in errot



In any case the other way to make it default to SPDIF is just to stick it all on the command line as follows I guess. That works.


Yes, I was hoping to get the default volume going too because I know you wanted that.



Still wonder why it won't save config though. Share Path is C:\Program Files\devnz\gbpvr\Dongle\mvpmc presumably no problem with that?


mvpmc just sees the share name, so I highly doubt that is a problem. In Vista I wouldn't recommend this because of the extra security on the Program Files folder.

Martin.

HtV
2007-05-20, 07:48 PM
In Vista I wouldn't recommend this because of the extra security on the Program Files folder.

You could rule out this as a reason by "moving" the share to c:\mvpmc. Afaik C:\program files has special security in xp aswell, allthough could be different/less as in Vista.

cya Hans

jksmurf
2007-05-21, 03:52 PM
You could rule out this as a reason by "moving" the share to c:\mvpmc. Afaik C:\program files has special security in xp aswell, allthough could be different/less as in Vista. cya Hans
Well I ruled it out by moving the share, but am still no further with it :confused:. Tried recreating the share, tried going back to Simple File Sharing, checked all previous recommendations. Stumped.

k.

mvallevand
2007-05-21, 03:59 PM
Well I ruled it out by moving the share, but am still no further with it :confused:. Tried recreating the share, tried going back to Simple File Sharing, checked all previous recommendations. Stumped.

I seem to remember that you had an NSLU2. If is online you could write the file there.

Martin

mvallevand
2007-05-21, 07:27 PM
Well I ruled it out by moving the share, but am still no further with it :confused:. Tried recreating the share, tried going back to Simple File Sharing, checked all previous recommendations. Stumped.

k.

k., if the guest account is giving you trouble with the rw, create another user with a password and use those in your dongle.bin.config

Here would be an example with an mvpmc user.



umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=mvpmc,password=mvpmc,rw
... back to normal


Note if you are worried about security on your home network (I'm not, my router is sufficient), remember that the guest account would be able to read the dongle.bin.config so any the info will not provide any additional security. It might get you around the problem.

Martin

jksmurf
2007-05-23, 04:11 PM
k., if the guest account is giving you trouble with the rw, create another user with a password and use those in your dongle.bin.config ... Here would be an example with an mvpmc user.


umount /etc/mvpmc
mount.cifs //192.168.1.10/mvpmc /etc/mvpmc -o username=mvpmc,password=mvpmc,rw
... back to normal


Well THAT worked :o ... so maybe it was the guest account permissions all along ...
So I then deleted the (new) mvpmc account, disabled simple file sharing, enabled the guest account, gave files ONLY full control in the mvpmc share (mine is located in in c:\program files\devnz\gbpvr\dongle\mvpmc) and that did NOT work.
So I looked at a few past threads. This one (http://forums.gbpvr.com/showpost.php?p=177752&postcount=3) shows a double back slash
mount.cifs //yourip/... while This one (http://forums.gbpvr.com/showpost.php?p=196848&postcount=8) (recommended for my setup) shows a single back slash
mount.cifs /yourip/.... So I tried both of them and whaddya know, DOUBLE backslash saves the config OK, single does not ... :confused:
I then turned OFF the guest account. That worked too. I learned more about shares than I ever wanted to...Martin's 10 ways to break the guest a/c was not far wrong... :D
So why does // work and / not?
Note if you are worried about security on your home network (I'm not, my router is sufficient), remember that the guest account would be able to read the dongle.bin.config so any the info will not provide any additional security. It might get you around the problem.
MartinHave a router too and if anone wants to mess with my mcpmc share, it's no biggie.

Can I ask another 2 questions?

Is it intended behaviour once settings are successfully saved, that a green-button MVP power off will load those settings on a green-button MVP power ON?
If those settings are not saved, but a commandline is used instead, is the intended behaviour the same, i.e. will a green-button MVP power off load those commandline settings on a green-button MVP power ON?Cheers

k.

mvallevand
2007-05-23, 04:49 PM
So why does // work and / not?

Because / is the root folder and my example was wrong, I will go through the forum this evening and fix it. (Done it was really just this thread)
You probably are most used to seeing the syntax in URL's http://.../...

On Windows it is the opposite net use m: \\..\.. because root is \



Is it intended behaviour once settings are successfully saved, that a green-button MVP power off will load those settings on a green-button MVP power ON?

They save when you hit Save Setting in the Main Menu Setup only. The reason for not-autosaving is that this function is intended to write to flash one day.



f those settings are not saved, but a commandline is used instead, is the intended behaviour the same, i.e. will a green-button MVP power off load those commandline settings on a green-button MVP power ON?

The command lines work everytime you start unless you override them with run time changes in Main Menu Setup or with the browser changes.

Martin

pz1
2007-05-23, 05:32 PM
I then turned OFF the guest account. That worked too. I learned more about shares than I ever wanted to...Martin's 10 ways to break the guest a/c was not far wrong... :D

Did you reboot your machine after this? I also observed that I could turn off Guest account and the thing continued to function properly. However after a reboot it did not work again!

jksmurf
2007-05-23, 11:26 PM
Did you reboot your machine after this? I also observed that I could turn off Guest account and the thing continued to function properly. However after a reboot it did not work again!
No I didn't try that... too tired to test :-)

k.