<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def is_connected(self):
 """ Check if the device is still connected. """

        for d in hid.enumerate(0, 0):
            if d['path'] == self.device:
                return True
        return False