<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 async def update_module( self, module: modules.AbstractModule, firmware_file: str, loop: asyncio.AbstractEventLoop = None) -> Tuple[bool, str]: """ Update a module's firmware. Returns (ok, message) where ok is True if the update succeeded and message is a human readable message. """

        details = (module.port, module.name())
        mod = self._attached_modules.pop(details[0] + details[1])
        try:
            new_mod = await self._backend.update_module(
                mod, firmware_file, loop)
        except modules.UpdateError as e:
            return False, e.msg
        else:
            new_details = new_mod.port + new_mod.device_info['model']
            self._attached_modules[new_details] = new_mod
            return True, 'firmware update successful'