Ticket #356: test.py

File test.py, 633 bytes (added by Carcinoma, 12 years ago)

calulates the illegal route

Line 
1#! /usr/bin/python
2import dbus
3import time;
4bus = dbus.SessionBus()
5conn = bus.get_object('org.navit_project.navit',
6                       '/org/navit_project/navit')
7iface = dbus.Interface(conn, dbus_interface='org.navit_project.navit');
8iter=iface.iter();
9navit=bus.get_object('org.navit_project.navit', conn.get_navit(iter));
10iface.iter_destroy(iter);
11navit_iface = dbus.Interface(navit, dbus_interface='org.navit_project.navit.navit');
12time.sleep(1);
13navit_iface.set_position('0x16ccae 0x692db8');
14time.sleep(1);
15navit_iface.set_destination('0x16d279 0x6922f5', '');
16time.sleep(1);
17navit_iface.set_center('0x16cdfa 0x6929d6');
18