Permalink
Browse files

fixes for new module layout from John Wiseman

  • Loading branch information...
1 parent ba99bb7 commit 41058de8ca2560aff8d1f3d96006436962c81db9 @tridge committed Jan 9, 2013
View
@@ -13,7 +13,7 @@
# The modules subdirectory contains the modules that come with
# mavproxy.
-sys.path.insert(0, os.path.join(os.path.dirname(__file__), 'modules'))
+sys.path.insert(0, os.path.join(os.path.dirname(os.path.realpath(__file__)), 'modules'))
# find the mavlink.py module
for d in [ 'pymavlink',
@@ -24,6 +24,7 @@
import select
from modules.lib import textconsole
+from modules.lib import mp_settings
class MPSettings(object):
def __init__(self):
File renamed without changes.
@@ -9,8 +9,9 @@
sys.path.insert(0, os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', '..', '..', 'cuav', 'lib'))
sys.path.insert(0, os.path.join(os.path.dirname(os.path.realpath(__file__)), '..', 'lib'))
-import scanner, mavutil, cuav_mosaic, mav_position, cuav_util, cuav_joe, block_xmit, mp_image, cuav_region, mp_slipmap, mp_settings
+import scanner, mavutil, cuav_mosaic, mav_position, cuav_util, cuav_joe, block_xmit, mp_image, cuav_region, mp_settings
from cam_params import CameraParams
+from modules.mavproxy_map import mp_slipmap
# allow for replaying of previous flights
if os.getenv('FAKE_CHAMELEON'):
File renamed without changes.
File renamed without changes.
File renamed without changes.
@@ -11,7 +11,7 @@
from modules.lib import wxconsole
from modules.lib import textconsole
from modules.lib import mp_elevation
-from modules.lib import mavutil
+import mavutil
from modules.lib import mp_util
class module_state(object):
@@ -9,6 +9,7 @@
import functools
import time
from mavproxy_map import mp_slipmap
+from modules.lib import mp_util
mpstate = None
@@ -91,7 +92,7 @@ def closest_waypoint(latlon):
def map_callback(obj):
'''called when an event happens on the slipmap'''
- import mp_slipmap
+ from mavproxy_map import mp_slipmap
state = mpstate.map_state
if not isinstance(obj, mp_slipmap.SlipMouseEvent):
return
File renamed without changes
@@ -9,7 +9,7 @@
import time
import wx
-from mavproxy_map import mp_util
+from modules.lib import mp_util
from mavproxy_map import mp_widgets
@@ -14,7 +14,7 @@
from mavproxy_map import mp_elevation
from mavproxy_map import mp_tile
-from mavproxy_map import mp_util
+from modules.lib import mp_util
from mavproxy_map import mp_widgets
@@ -21,7 +21,7 @@
import cv
-from mavproxy_map import mp_util
+from modules.lib import mp_util
class TileException(Exception):
'''tile error class'''
@@ -16,7 +16,7 @@
import array
import math
import multiprocessing
-import mp_util
+from modules.lib import mp_util
import tempfile
class NoSuchTileError(Exception):
File renamed without changes.

0 comments on commit 41058de

Please sign in to comment.