<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def add_service(self, name, long_name, preregistered=False, notify=True):
 """Add a service to the list of tracked services. Args: name (string):
 A unique short service name for the service long_name (string):
 A longer, user friendly name for the service preregistered (bool):
 Whether this service is an expected preregistered service. notify (bool):
 Send notifications about this service to all clients Returns: awaitable: If notify is True, an awaitable for the notifications. Otherwise None. """


        if name in self.services:
            raise ArgumentError("Could not add service because the long_name is taken", long_name=long_name)

        serv_state = states.ServiceState(name, long_name, preregistered)

        service = {
            'state': serv_state,
            'heartbeat_threshold': 600
        }

        self.services[name] = service

        if notify:
            return self._notify_update(name, 'new_service', self.service_info(name))

        return None