code: def shutdown(self):
          
          status = self.can.close(self.handle)
  
          if status != CANAL_ERROR_SUCCESS:
              raise CanError("could not shut down bus: status == {}".format(status))
docs: Shuts down connection to the device safely.
  
          :raise cam.CanError: is closing the connection did not work