Skip to content

Commit

Permalink
Use new events defined in stormdrain that split bounds update and dat…
Browse files Browse the repository at this point in the history
…a reflow
  • Loading branch information
deeplycloudy committed Oct 16, 2013
1 parent 3338a1b commit dfbd88c
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
5 changes: 2 additions & 3 deletions LMA/hdf5_lma.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,7 @@ def __init__(self, h5filename, table_path=None, target=None, mode='r'):
self.table = self.h5file.getNode(table_path)
self.data = self.table[:]

self.bounds_updated_xchg = get_exchange('SD_bounds_updated')
self.bounds_updated_xchg.attach(self)
get_exchange('SD_reflow_start').attach(self)

flash_table_path = table_path.replace('events', 'flashes')
try:
Expand Down Expand Up @@ -58,7 +57,7 @@ def update(self, index_name="hdf_row_idx", field_names=None):


def send(self, msg):
""" SD_bounds_updated messages are sent here """
""" SD_reflow_start messages are sent here """

# do we send the whole events table, or somehow dynamically determine that?

Expand Down
5 changes: 2 additions & 3 deletions LMA/live.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,7 @@ class LiveLMADataset(object):

def __init__(self, target=None, host=None, basedate=None):
self.target = target
self.bounds_updated_xchg = get_exchange('SD_bounds_updated')
self.bounds_updated_xchg.attach(self)
get_exchange('SD_reflow_start').attach(self)

self._t_offset = 0.0
if basedate is not None:
Expand Down Expand Up @@ -123,7 +122,7 @@ def show(self, header, newdata):
self.send("B4D_LMAnewsources_live")

def send(self, msg):
""" SD_bounds_updated messages are sent here """
""" SD_reflow_data messages are sent here """

# do we send the whole events table, or somehow dynamically determine that?
if len(self._dataq) > 0:
Expand Down
6 changes: 5 additions & 1 deletion NLDN.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,11 @@


class GroundMarkerHeightController(object):

""" When the bounds of the current view change, it's necessary to adjust
the height at which the ground-level markers are plotted, since they should be along
the bottom edge of the height view (their height is actually arbitrary) in order
to remain visible.
"""
def __init__(self, target=None, initial_height=0.0, alt_name='alt', alt_factor=1000.0):

self.bounds_updated_xchg = get_exchange('SD_bounds_updated')
Expand Down

0 comments on commit dfbd88c

Please sign in to comment.