Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 8 additions & 4 deletions dbus.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,11 @@ def __init__(self, bus, path):
self.method_inargs = method_inargs
self.method_outargs = method_outargs

bus.register_object(object_path=path, interface_info=interface_info, method_call_closure=self.on_method_call)
# Help on method register_object in module pydbus.registration:
# register_object(self, path, object, node_info) method of pydbus.bus.Bus instance

bus.register_object(path, self, self.__doc__)
# bus.publish(path,self)

def run(self):
self.loop.run()
Expand Down Expand Up @@ -68,9 +72,9 @@ def HelloWorld(self, a, b):


if __name__ == '__main__':
from pydbus import SessionBus
bus = SessionBus()
from pydbus import SystemBus
bus = SystemBus()
bus.own_name(name = 'net.lvht')

foo = Foo(bus=bus.con, path='/net/lvht/Foo')
foo = Foo(bus=bus, path='/net/lvht/Foo')
foo.run()
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
future
evdev
PyBluez
pydbus
pydbus==0.5.1
#-e git://github.com/LEW21/pydbus.git@d6c1a27a2bd17280f63b0093872ffa89d8658f08#egg=pydbus