<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def restart(self, wait=True, timeout=None, wait_polling_interval=None):
 """Restart b2g, waiting for the adb connection to become stable. :param timeout: Maximum time to wait for restart. :param wait_polling_interval: Interval at which to poll for device readiness. """

        self.stop(timeout=timeout)
        self.start(wait, timeout=timeout, wait_polling_interval=wait_polling_interval)