diff --git a/voltha/adapters/asfvolt16_olt/asfvolt16_device_handler.py b/voltha/adapters/asfvolt16_olt/asfvolt16_device_handler.py
index 851dd11..1539246 100644
--- a/voltha/adapters/asfvolt16_olt/asfvolt16_device_handler.py
+++ b/voltha/adapters/asfvolt16_olt/asfvolt16_device_handler.py
@@ -927,10 +927,22 @@
             msg = {'proxy_address': child_device.proxy_address,
                    'event': 'activation-completed', 'event_data': ind_info}
 
+            balSubTermInd = {}
+            serial_number=(ind_info['_vendor_id'] +
+                           ind_info['_vendor_specific'])
+            balSubTermInd["serial_number"] = serial_number.__str__()
+            balSubTermInd["registration_id"] = ind_info['registration_id'].__str__()
+            self.log.info('onu_activated:registration_id',balSubTermInd["registration_id"])
+            balSubTermInd["device_id"] = (self.device_id).__str__()
+
             # Send the event message to the ONU adapter
             self.adapter_agent.publish_inter_adapter_message(child_device.id,
                                                              msg)
             if ind_info['activation_successful'] is True:
+                self.handle_alarms(self.device_id,"onu",\
+                       ind_info['_pon_id'],\
+                       "ONU_ACTIVATED",1,"high",\
+                       balSubTermInd)
                 for key, v_ont_ani in self.v_ont_anis.items():
                     if v_ont_ani.v_ont_ani.data.onu_id == \
                             child_device.proxy_address.onu_id:
@@ -960,13 +972,22 @@
     }
 
     def handle_sub_term_ind(self, ind_info):
+        serial_number=(ind_info['_vendor_id'] +
+                           ind_info['_vendor_specific'])
         child_device = self.adapter_agent.get_child_device(
             self.device_id,
-            serial_number=(ind_info['_vendor_id'] +
-                           ind_info['_vendor_specific']))
+            serial_number=serial_number)
         if child_device is None:
             self.log.info('Onu-is-not-configured', olt_id=self.olt_id,
                           pon_ni=ind_info['_pon_id'], onu_data=ind_info)
+            if ind_info['_sub_group_type'] == 'onu_discovery':
+                balSubTermDisc = {}
+                balSubTermDisc["serial_number"] = serial_number.__str__()
+                balSubTermDisc["device_id"] = (self.device_id).__str__()
+                self.handle_alarms(self.device_id,"onu",\
+                               ind_info['_pon_id'],\
+                               "ONU_DISCOVERED",1,"high",\
+                               balSubTermDisc)
             return
 
         handler = self.onu_handlers.get(child_device.oper_status)
diff --git a/voltha/adapters/asfvolt16_olt/asfvolt16_ind_handler.py b/voltha/adapters/asfvolt16_olt/asfvolt16_ind_handler.py
old mode 100755
new mode 100644
index 2ffa2d2..826ff4f
--- a/voltha/adapters/asfvolt16_olt/asfvolt16_ind_handler.py
+++ b/voltha/adapters/asfvolt16_olt/asfvolt16_ind_handler.py
@@ -42,8 +42,10 @@
         ind_info = dict()
         ind_info['_object_type'] = 'access_terminal_indication'
         ind_info['_sub_group_type'] = 'access_terminal_indication'
-        if indication.access_term_ind.data.admin_state == \
-                bal_model_types_pb2.BAL_STATE_UP:
+        if ((indication.access_term_ind.data.admin_state == \
+                bal_model_types_pb2.BAL_STATE_UP) and \
+                (indication.access_term_ind.data.oper_status == \
+                bal_model_types_pb2.BAL_STATUS_UP)):
             ind_info['activation_successful'] = True
         else:
             ind_info['activation_successful'] = False
@@ -242,10 +244,15 @@
         ind_info['_vendor_id'] = onu_data.data.serial_number.vendor_id
         ind_info['_vendor_specific'] = \
             onu_data.data.serial_number.vendor_specific
-        if ((bal_model_types_pb2.BAL_STATE_DOWN == onu_data.data.admin_state)\
-            or (bal_model_types_pb2.BAL_STATUS_UP != onu_data.data.oper_status)):
+        self.log.info('registration-id-in-bal-subs-term-ind-is',\
+                       registration_id=onu_data.data.registration_id[:36])
+        ind_info['registration_id'] = onu_data.data.registration_id[:36]
+        ind_info['activation_successful'] = None
+        if (bal_model_types_pb2.BAL_STATE_DOWN == onu_data.data.admin_state or
+            bal_model_types_pb2.BAL_STATUS_UP != onu_data.data.oper_status):
             ind_info['activation_successful'] = False
-        elif (bal_model_types_pb2.BAL_STATE_UP == onu_data.data.admin_state):
+        elif (bal_model_types_pb2.BAL_STATE_UP == onu_data.data.admin_state and
+            bal_model_types_pb2.BAL_STATUS_UP == onu_data.data.oper_status):
             ind_info['activation_successful'] = True
 
         reactor.callLater(0,
diff --git a/voltha/adapters/asfvolt16_olt/asfvolt16_olt.py b/voltha/adapters/asfvolt16_olt/asfvolt16_olt.py
index 1f4c8b1..aaa1699 100644
--- a/voltha/adapters/asfvolt16_olt/asfvolt16_olt.py
+++ b/voltha/adapters/asfvolt16_olt/asfvolt16_olt.py
@@ -33,7 +33,7 @@
                                                device_handler_class=Asfvolt16Handler,
                                                name='asfvolt16_olt',
                                                vendor='Edgecore',
-                                               version='0.96',
+                                               version='0.97',
                                                device_type='asfvolt16_olt')
         # register for adapter messages
         self.port = 60001
