src/eric7/Documentation/Source/eric7.MicroPython.Devices.TeensyDevices.html

branch
eric7
changeset 9756
9854647c8c5c
child 9765
6378da868bb0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/eric7/Documentation/Source/eric7.MicroPython.Devices.TeensyDevices.html	Mon Feb 13 17:49:52 2023 +0100
@@ -0,0 +1,447 @@
+<!DOCTYPE html>
+<html><head>
+<title>eric7.MicroPython.Devices.TeensyDevices</title>
+<meta charset="UTF-8">
+<link rel="stylesheet" href="styles.css">
+</head>
+<body>
+<a NAME="top" ID="top"></a>
+<h1>eric7.MicroPython.Devices.TeensyDevices</h1>
+
+<p>
+Module implementing the device interface class for Teensy boards with MicroPython.
+</p>
+<h3>Global Attributes</h3>
+
+<table>
+<tr><td>None</td></tr>
+</table>
+<h3>Classes</h3>
+
+<table>
+
+<tr>
+<td><a href="#TeensyDevice">TeensyDevice</a></td>
+<td>Class implementing the device for Teensy boards with MicroPython.</td>
+</tr>
+</table>
+<h3>Functions</h3>
+
+<table>
+
+<tr>
+<td><a href="#createDevice">createDevice</a></td>
+<td>Function to instantiate a MicroPython device object.</td>
+</tr>
+</table>
+<hr />
+<hr />
+<a NAME="TeensyDevice" ID="TeensyDevice"></a>
+<h2>TeensyDevice</h2>
+
+<p>
+    Class implementing the device for Teensy boards with MicroPython.
+</p>
+<h3>Derived from</h3>
+BaseDevice
+<h3>Class Attributes</h3>
+
+<table>
+<tr><td>None</td></tr>
+</table>
+<h3>Class Methods</h3>
+
+<table>
+<tr><td>None</td></tr>
+</table>
+<h3>Methods</h3>
+
+<table>
+
+<tr>
+<td><a href="#TeensyDevice.__init__">TeensyDevice</a></td>
+<td>Constructor</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.__createTeensyMenu">__createTeensyMenu</a></td>
+<td>Private method to create the microbit submenu.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.__firmwareVersionResponse">__firmwareVersionResponse</a></td>
+<td>Private method handling the response of the latest version request.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.__showFirmwareVersions">__showFirmwareVersions</a></td>
+<td>Private slot to show the firmware version of the connected device and the available firmware version.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.__showFlashInstructions">__showFlashInstructions</a></td>
+<td>Private method to show a message box with instruction to flash the Teensy.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.__startTeensyLoader">__startTeensyLoader</a></td>
+<td>Private method to start the 'Teensy Loader' application.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.addDeviceMenuEntries">addDeviceMenuEntries</a></td>
+<td>Public method to add device specific entries to the given menu.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.canRunScript">canRunScript</a></td>
+<td>Public method to determine, if a script can be executed.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.canStartFileManager">canStartFileManager</a></td>
+<td>Public method to determine, if a File Manager can be started.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.canStartPlotter">canStartPlotter</a></td>
+<td>Public method to determine, if a Plotter can be started.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.canStartRepl">canStartRepl</a></td>
+<td>Public method to determine, if a REPL can be started.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.deviceName">deviceName</a></td>
+<td>Public method to get the name of the device.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.forceInterrupt">forceInterrupt</a></td>
+<td>Public method to determine the need for an interrupt when opening the serial connection.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.getDocumentationUrl">getDocumentationUrl</a></td>
+<td>Public method to get the device documentation URL.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.getFirmwareUrl">getFirmwareUrl</a></td>
+<td>Public method to get the device firmware download URL.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.runScript">runScript</a></td>
+<td>Public method to run the given Python script.</td>
+</tr>
+<tr>
+<td><a href="#TeensyDevice.setButtons">setButtons</a></td>
+<td>Public method to enable the supported action buttons.</td>
+</tr>
+</table>
+<h3>Static Methods</h3>
+
+<table>
+<tr><td>None</td></tr>
+</table>
+
+<a NAME="TeensyDevice.__init__" ID="TeensyDevice.__init__"></a>
+<h4>TeensyDevice (Constructor)</h4>
+<b>TeensyDevice</b>(<i>microPythonWidget, deviceType, parent=None</i>)
+
+<p>
+        Constructor
+</p>
+<dl>
+
+<dt><i>microPythonWidget</i> (MicroPythonWidget)</dt>
+<dd>
+reference to the main MicroPython widget
+</dd>
+<dt><i>deviceType</i> (str)</dt>
+<dd>
+device type assigned to this device interface
+</dd>
+<dt><i>parent</i> (QObject)</dt>
+<dd>
+reference to the parent object
+</dd>
+</dl>
+<a NAME="TeensyDevice.__createTeensyMenu" ID="TeensyDevice.__createTeensyMenu"></a>
+<h4>TeensyDevice.__createTeensyMenu</h4>
+<b>__createTeensyMenu</b>(<i></i>)
+
+<p>
+        Private method to create the microbit submenu.
+</p>
+<a NAME="TeensyDevice.__firmwareVersionResponse" ID="TeensyDevice.__firmwareVersionResponse"></a>
+<h4>TeensyDevice.__firmwareVersionResponse</h4>
+<b>__firmwareVersionResponse</b>(<i>reply</i>)
+
+<p>
+        Private method handling the response of the latest version request.
+</p>
+<dl>
+
+<dt><i>reply</i> (QNetworkReply)</dt>
+<dd>
+reference to the reply object
+</dd>
+</dl>
+<a NAME="TeensyDevice.__showFirmwareVersions" ID="TeensyDevice.__showFirmwareVersions"></a>
+<h4>TeensyDevice.__showFirmwareVersions</h4>
+<b>__showFirmwareVersions</b>(<i></i>)
+
+<p>
+        Private slot to show the firmware version of the connected device and the
+        available firmware version.
+</p>
+<a NAME="TeensyDevice.__showFlashInstructions" ID="TeensyDevice.__showFlashInstructions"></a>
+<h4>TeensyDevice.__showFlashInstructions</h4>
+<b>__showFlashInstructions</b>(<i></i>)
+
+<p>
+        Private method to show a message box with instruction to flash the Teensy.
+</p>
+<a NAME="TeensyDevice.__startTeensyLoader" ID="TeensyDevice.__startTeensyLoader"></a>
+<h4>TeensyDevice.__startTeensyLoader</h4>
+<b>__startTeensyLoader</b>(<i></i>)
+
+<p>
+        Private method to start the 'Teensy Loader' application.
+</p>
+<p>
+        Note: The application must be accessible via the application search path.
+</p>
+<a NAME="TeensyDevice.addDeviceMenuEntries" ID="TeensyDevice.addDeviceMenuEntries"></a>
+<h4>TeensyDevice.addDeviceMenuEntries</h4>
+<b>addDeviceMenuEntries</b>(<i>menu</i>)
+
+<p>
+        Public method to add device specific entries to the given menu.
+</p>
+<dl>
+
+<dt><i>menu</i> (QMenu)</dt>
+<dd>
+reference to the context menu
+</dd>
+</dl>
+<a NAME="TeensyDevice.canRunScript" ID="TeensyDevice.canRunScript"></a>
+<h4>TeensyDevice.canRunScript</h4>
+<b>canRunScript</b>(<i></i>)
+
+<p>
+        Public method to determine, if a script can be executed.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+tuple containing a flag indicating it is safe to start a
+            Plotter and a reason why it cannot.
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+tuple of (bool, str)
+</dd>
+</dl>
+<a NAME="TeensyDevice.canStartFileManager" ID="TeensyDevice.canStartFileManager"></a>
+<h4>TeensyDevice.canStartFileManager</h4>
+<b>canStartFileManager</b>(<i></i>)
+
+<p>
+        Public method to determine, if a File Manager can be started.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+tuple containing a flag indicating it is safe to start a
+            File Manager and a reason why it cannot.
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+tuple of (bool, str)
+</dd>
+</dl>
+<a NAME="TeensyDevice.canStartPlotter" ID="TeensyDevice.canStartPlotter"></a>
+<h4>TeensyDevice.canStartPlotter</h4>
+<b>canStartPlotter</b>(<i></i>)
+
+<p>
+        Public method to determine, if a Plotter can be started.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+tuple containing a flag indicating it is safe to start a
+            Plotter and a reason why it cannot.
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+tuple of (bool, str)
+</dd>
+</dl>
+<a NAME="TeensyDevice.canStartRepl" ID="TeensyDevice.canStartRepl"></a>
+<h4>TeensyDevice.canStartRepl</h4>
+<b>canStartRepl</b>(<i></i>)
+
+<p>
+        Public method to determine, if a REPL can be started.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+tuple containing a flag indicating it is safe to start a REPL
+            and a reason why it cannot.
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+tuple of (bool, str)
+</dd>
+</dl>
+<a NAME="TeensyDevice.deviceName" ID="TeensyDevice.deviceName"></a>
+<h4>TeensyDevice.deviceName</h4>
+<b>deviceName</b>(<i></i>)
+
+<p>
+        Public method to get the name of the device.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+name of the device
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+str
+</dd>
+</dl>
+<a NAME="TeensyDevice.forceInterrupt" ID="TeensyDevice.forceInterrupt"></a>
+<h4>TeensyDevice.forceInterrupt</h4>
+<b>forceInterrupt</b>(<i></i>)
+
+<p>
+        Public method to determine the need for an interrupt when opening the
+        serial connection.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+flag indicating an interrupt is needed
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+bool
+</dd>
+</dl>
+<a NAME="TeensyDevice.getDocumentationUrl" ID="TeensyDevice.getDocumentationUrl"></a>
+<h4>TeensyDevice.getDocumentationUrl</h4>
+<b>getDocumentationUrl</b>(<i></i>)
+
+<p>
+        Public method to get the device documentation URL.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+documentation URL of the device
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+str
+</dd>
+</dl>
+<a NAME="TeensyDevice.getFirmwareUrl" ID="TeensyDevice.getFirmwareUrl"></a>
+<h4>TeensyDevice.getFirmwareUrl</h4>
+<b>getFirmwareUrl</b>(<i></i>)
+
+<p>
+        Public method to get the device firmware download URL.
+</p>
+<dl>
+<dt>Return:</dt>
+<dd>
+firmware download URL of the device
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+str
+</dd>
+</dl>
+<a NAME="TeensyDevice.runScript" ID="TeensyDevice.runScript"></a>
+<h4>TeensyDevice.runScript</h4>
+<b>runScript</b>(<i>script</i>)
+
+<p>
+        Public method to run the given Python script.
+</p>
+<dl>
+
+<dt><i>script</i> (str)</dt>
+<dd>
+script to be executed
+</dd>
+</dl>
+<a NAME="TeensyDevice.setButtons" ID="TeensyDevice.setButtons"></a>
+<h4>TeensyDevice.setButtons</h4>
+<b>setButtons</b>(<i></i>)
+
+<p>
+        Public method to enable the supported action buttons.
+</p>
+<div align="right"><a href="#top">Up</a></div>
+<hr />
+<hr />
+<a NAME="createDevice" ID="createDevice"></a>
+<h2>createDevice</h2>
+<b>createDevice</b>(<i>microPythonWidget, deviceType, vid, pid, boardName, serialNumber</i>)
+
+<p>
+    Function to instantiate a MicroPython device object.
+</p>
+<dl>
+
+<dt><i>microPythonWidget</i> (MicroPythonWidget)</dt>
+<dd>
+reference to the main MicroPython widget
+</dd>
+<dt><i>deviceType</i> (str)</dt>
+<dd>
+device type assigned to this device interface
+</dd>
+<dt><i>vid</i> (int)</dt>
+<dd>
+vendor ID
+</dd>
+<dt><i>pid</i> (int)</dt>
+<dd>
+product ID
+</dd>
+<dt><i>boardName</i> (str)</dt>
+<dd>
+name of the board
+</dd>
+<dt><i>serialNumber</i> (str)</dt>
+<dd>
+serial number of the board
+</dd>
+</dl>
+<dl>
+<dt>Return:</dt>
+<dd>
+reference to the instantiated device object
+</dd>
+</dl>
+<dl>
+<dt>Return Type:</dt>
+<dd>
+PyBoardDevice
+</dd>
+</dl>
+<div align="right"><a href="#top">Up</a></div>
+<hr />
+</body></html>
\ No newline at end of file

eric ide

mercurial