Dear visitor, welcome to VDR Portal. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.
|
|
Source code |
1 2 3 4 5 |
cMenuMain *mainmenu = new cMenuMain;
cString msg;
for (cOsdItem *o = mainmenu->First(); o; o = mainmenu->Next(o))
msg = cString::sprintf("%s%s\n", (*msg ? *msg : ""), o->Text());
return msg;
|
This post has been edited 1 times, last edit by "mini73" (Apr 28th 2011, 12:32am)
|
|
Source code |
1 2 3 4 |
vdr.plugins.SVDRPCommand(Pluginname, Befehl) vdr.plugins.Service(Befehl, Parameter) vdr.menu.Select() vdr.SVDRPCommand(Befehl) |
|
|
Source code |
1 2 |
/Plugins/<Pluginame>/ /Menu/... |
This post has been edited 1 times, last edit by "Mreimer" (Mar 14th 2011, 1:20pm)
Quoted
Originally posted by mini73
Und ich brauche es hauptsächlich für die Steuerung von ein paar Plugins.
This post has been edited 2 times, last edit by "Keine_Ahnung" (Mar 14th 2011, 2:03pm)
Quoted
Original von Keine_Ahnung
Quoted
Originally posted by mini73
Und ich brauche es hauptsächlich für die Steuerung von ein paar Plugins.
Wäre es da nicht sinnvoller dann in diesen Plugins die Änderungen einzubauen als die irgendwie über eine Menüemulation fernzusteuern?
|
|
Source code |
1 |
dbus-send --dest='vdr' /Plugins/dynamite vdr.plugins.SVDRPCommand string:'ATTD' string:'/dev/dvb/adapter0/frontend0' |
|
|
Source code |
1 2 |
dbus-send --dest='vdr' /Menu vdr.menu.List dbus-send --dest='vdr' /Menu/4 vdr.menu.List |
|
|
Source code |
1 |
dbus-send --dest='vdr' /Menu/4/7 vdr.menu.Select |
|
|
Source code |
1 2 |
dbus-send --dest='vdr' /Recordings vdr.recordings.New ... dbus-send --dest='vdr' /EPG vdr.epg.New ... |
Quoted
Originally posted by mini73
Das hab ich mir schon gedacht. Das Auslösen von Menüaktionen sehe ich noch nicht so ganz als Problem (das wird dann eher "Absicht").
Quoted
Originally posted by Mreimer
Sendet Device-Kit nicht ohnehin eine ganze Reihe von Deviceabhängigen Nachrichten über Dbus? Nehme doch die um dynamisch Devices einzuhängen. Dann braucht der VDR selber keine allgemeine Dbus-Schnittstelle.
Quoted
Original von steffen_b
@mini73: https://github.com/kersten/vdr-plugin-dbus kennst du aber oder?
This post has been edited 1 times, last edit by "mini73" (Apr 28th 2011, 12:30am)
|
|
Source code |
1 2 3 |
method return sender=:1.38 -> dest=:1.39 reply_serial=2 int32 900 string "Opening femon plugin" |
|
|
Source code |
1 2 3 |
method return sender=:1.38 -> dest=:1.42 reply_serial=2 int32 250 string "Key "Menu" accepted" |
|
|
Source code |
1 2 3 |
method return sender=:1.38 -> dest=:1.44 reply_serial=2 int32 250 string "Remote control disabled" |
|
|
Source code |
1 2 3 |
method return sender=:1.38 -> dest=:1.45 reply_serial=2 int32 250 string "Remote control enabled" |
|
|
Source code |
1 2 3 4 5 6 7 |
method return sender=:1.38 -> dest=:1.46 reply_serial=2 int32 250 int32 1 int32 6477 uint64 1303385880 uint64 1303389900 string "Lonely Planet - Ab vom Schuss" |

Ich nutze die lircrc und rufe damit dann auch svdrp Befehle (die dann letztendlich Plugins starten, z.B. die epgsearch Kanalanzeige) per Fernbedienungstasten auf, und mit der dbus Variante fühlt sich das flüssiger an als die svdrp Variante mit netcat. Werde mich dann später nochmal genauer damit beschäftigen, aber da ich bei mir auch viel per Python und svdrp EPG mache scheint das mit dem dbus auch ne gute Idee zu sein.|
|
Source code |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
cString cPluginCallplugin::SVDRPCommand(const char *Command, const char *Option, int &ReplyCode)
{
// Process SVDRP commands this plugin implements
if (strcasecmp(Command, "CALL") == 0) {
if (cRemote::CallPlugin(Option))
return cString::sprintf("Opening %s plugin", Option);
else {
ReplyCode = 550; // Requested action not taken
return cString::sprintf("Opening %s plugin failed!", Option);
}
}
return NULL;
}
|