'Allow to toggle the NOP keepalive for those sad clients that
can\'t even handle a NOP instruction. This is turned off by the
protocol_flag NOPKEEPALIVE (settable e.g. by the default
`@option` command).'

def toggle_nop_keepalive(self):

    if (self.nop_keep_alive and self.nop_keep_alive.running):
        self.nop_keep_alive.stop()
    else:
        self.nop_keep_alive = LoopingCall(self._send_nop_keepalive)
        self.nop_keep_alive.start(30, now=False)
