Guest User

Untitled

a guest
Nov 12th, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.73 KB | None | 0 0
  1. #!/usr/bin/env python
  2. import dbus
  3. import gobject
  4. gobject.threads_init()
  5.  
  6. from dbus import glib
  7. glib.init_threads()
  8.  
  9. # Create a session bus.
  10. import dbus
  11. bus = dbus.SessionBus()
  12.  
  13. # Create an object that will proxy for a particular remote object.
  14. remote_object = bus.get_object("org.navit_project.navit", # Connection name
  15. "/org/navit_project/navit/default_navit" ) # Object's path
  16.  
  17. # Introspection returns an XML document containing information
  18. # about the methods supported by an interface.
  19. print "Introspection data:"
  20. print remote_object.Introspect()
  21.  
  22. bookmark = dbus.Interface(remote_object, dbus_interface="org.navit_project.navit.bookmarks")
  23. print "Setting destination"
  24. bookmark.set_as_destination("Park")
Add Comment
Please, Sign In to add comment