src/eric7/MicroPython/Devices/STLinkDevices.py

branch
mpy_network
changeset 9989
286c2a21f36f
parent 9972
68ac01294544
child 10069
435cc5875135
equal deleted inserted replaced
9988:1ba9d07ba9da 9989:286c2a21f36f
466 @pyqtSlot() 466 @pyqtSlot()
467 def __resetDevice(self): 467 def __resetDevice(self):
468 """ 468 """
469 Private slot to reset the connected device. 469 Private slot to reset the connected device.
470 """ 470 """
471 self.microPython.deviceInterface().execute( 471 if self.microPython.isConnected():
472 "import machine\nmachine.reset()\n", mode=self._submitMode 472 self.executeCommands(
473 ) 473 "import machine\nmachine.reset()\n", mode=self._submitMode
474 )
474 475
475 476
476 def createDevice(microPythonWidget, deviceType, vid, pid, boardName, serialNumber): 477 def createDevice(microPythonWidget, deviceType, vid, pid, boardName, serialNumber):
477 """ 478 """
478 Function to instantiate a MicroPython device object. 479 Function to instantiate a MicroPython device object.

eric ide

mercurial