|
1 <!DOCTYPE html> |
|
2 <html><head> |
|
3 <title>eric7.MicroPython.Devices.CircuitPythonUpdater.CircuitPythonUpdaterInterface</title> |
|
4 <meta charset="UTF-8"> |
|
5 <link rel="stylesheet" href="styles.css"> |
|
6 </head> |
|
7 <body> |
|
8 <a NAME="top" ID="top"></a> |
|
9 <h1>eric7.MicroPython.Devices.CircuitPythonUpdater.CircuitPythonUpdaterInterface</h1> |
|
10 |
|
11 <p> |
|
12 Module implementing an interface to the 'circup' package. |
|
13 </p> |
|
14 <h3>Global Attributes</h3> |
|
15 |
|
16 <table> |
|
17 <tr><td>None</td></tr> |
|
18 </table> |
|
19 <h3>Classes</h3> |
|
20 |
|
21 <table> |
|
22 |
|
23 <tr> |
|
24 <td><a href="#CircuitPythonUpdaterInterface">CircuitPythonUpdaterInterface</a></td> |
|
25 <td>Class implementing an interface to the 'circup' package.</td> |
|
26 </tr> |
|
27 </table> |
|
28 <h3>Functions</h3> |
|
29 |
|
30 <table> |
|
31 |
|
32 <tr> |
|
33 <td><a href="#isCircupAvailable">isCircupAvailable</a></td> |
|
34 <td>Function to check for the availability of 'circup'.</td> |
|
35 </tr> |
|
36 </table> |
|
37 <hr /> |
|
38 <hr /> |
|
39 <a NAME="CircuitPythonUpdaterInterface" ID="CircuitPythonUpdaterInterface"></a> |
|
40 <h2>CircuitPythonUpdaterInterface</h2> |
|
41 |
|
42 <p> |
|
43 Class implementing an interface to the 'circup' package. |
|
44 </p> |
|
45 <h3>Derived from</h3> |
|
46 QObject |
|
47 <h3>Class Attributes</h3> |
|
48 |
|
49 <table> |
|
50 <tr><td>None</td></tr> |
|
51 </table> |
|
52 <h3>Class Methods</h3> |
|
53 |
|
54 <table> |
|
55 <tr><td>None</td></tr> |
|
56 </table> |
|
57 <h3>Methods</h3> |
|
58 |
|
59 <table> |
|
60 |
|
61 <tr> |
|
62 <td><a href="#CircuitPythonUpdaterInterface.__init__">CircuitPythonUpdaterInterface</a></td> |
|
63 <td>Constructor</td> |
|
64 </tr> |
|
65 <tr> |
|
66 <td><a href="#CircuitPythonUpdaterInterface.__aboutCircup">__aboutCircup</a></td> |
|
67 <td>Private slot to show some info about 'circup'.</td> |
|
68 </tr> |
|
69 <tr> |
|
70 <td><a href="#CircuitPythonUpdaterInterface.__addBundle">__addBundle</a></td> |
|
71 <td>Private slot to add a bundle to the local bundles list, by "user/repo" github string.</td> |
|
72 </tr> |
|
73 <tr> |
|
74 <td><a href="#CircuitPythonUpdaterInterface.__doUpdateModules">__doUpdateModules</a></td> |
|
75 <td>Private method to perform the update of a list of modules.</td> |
|
76 </tr> |
|
77 <tr> |
|
78 <td><a href="#CircuitPythonUpdaterInterface.__generateRequirements">__generateRequirements</a></td> |
|
79 <td>Private slot to generate requirements for the connected device.</td> |
|
80 </tr> |
|
81 <tr> |
|
82 <td><a href="#CircuitPythonUpdaterInterface.__installFromAvailable">__installFromAvailable</a></td> |
|
83 <td>Private slot to install modules onto the connected device.</td> |
|
84 </tr> |
|
85 <tr> |
|
86 <td><a href="#CircuitPythonUpdaterInterface.__installFromCode">__installFromCode</a></td> |
|
87 <td>Private slot to install modules based on the 'code.py' file of the connected device.</td> |
|
88 </tr> |
|
89 <tr> |
|
90 <td><a href="#CircuitPythonUpdaterInterface.__installModules">__installModules</a></td> |
|
91 <td>Private method to install the given list of modules.</td> |
|
92 </tr> |
|
93 <tr> |
|
94 <td><a href="#CircuitPythonUpdaterInterface.__installRequirements">__installRequirements</a></td> |
|
95 <td>Private slot to install modules determined by a requirements file.</td> |
|
96 </tr> |
|
97 <tr> |
|
98 <td><a href="#CircuitPythonUpdaterInterface.__listOutdatedModules">__listOutdatedModules</a></td> |
|
99 <td>Private slot to list the outdated modules of the connected device.</td> |
|
100 </tr> |
|
101 <tr> |
|
102 <td><a href="#CircuitPythonUpdaterInterface.__removeBundle">__removeBundle</a></td> |
|
103 <td>Private slot to remove one or more bundles from the local bundles list.</td> |
|
104 </tr> |
|
105 <tr> |
|
106 <td><a href="#CircuitPythonUpdaterInterface.__showAvailableModules">__showAvailableModules</a></td> |
|
107 <td>Private slot to show the available modules.</td> |
|
108 </tr> |
|
109 <tr> |
|
110 <td><a href="#CircuitPythonUpdaterInterface.__showBundles">__showBundles</a></td> |
|
111 <td>Private slot to show the available bundles (default and local).</td> |
|
112 </tr> |
|
113 <tr> |
|
114 <td><a href="#CircuitPythonUpdaterInterface.__showBundlesModules">__showBundlesModules</a></td> |
|
115 <td>Private slot to show the available bundles (default and local) with their modules.</td> |
|
116 </tr> |
|
117 <tr> |
|
118 <td><a href="#CircuitPythonUpdaterInterface.__showInstalledModules">__showInstalledModules</a></td> |
|
119 <td>Private slot to show the modules installed on the connected device.</td> |
|
120 </tr> |
|
121 <tr> |
|
122 <td><a href="#CircuitPythonUpdaterInterface.__uninstallModules">__uninstallModules</a></td> |
|
123 <td>Private slot to uninstall modules from the connected device.</td> |
|
124 </tr> |
|
125 <tr> |
|
126 <td><a href="#CircuitPythonUpdaterInterface.__updateAllModules">__updateAllModules</a></td> |
|
127 <td>Private slot to update all modules of the connected device.</td> |
|
128 </tr> |
|
129 <tr> |
|
130 <td><a href="#CircuitPythonUpdaterInterface.__updateModules">__updateModules</a></td> |
|
131 <td>Private slot to update the modules of the connected device.</td> |
|
132 </tr> |
|
133 <tr> |
|
134 <td><a href="#CircuitPythonUpdaterInterface.installCircup">installCircup</a></td> |
|
135 <td>Public slot to install the 'circup' package via pip.</td> |
|
136 </tr> |
|
137 <tr> |
|
138 <td><a href="#CircuitPythonUpdaterInterface.populateMenu">populateMenu</a></td> |
|
139 <td>Public method to populate the 'circup' menu.</td> |
|
140 </tr> |
|
141 </table> |
|
142 <h3>Static Methods</h3> |
|
143 |
|
144 <table> |
|
145 <tr><td>None</td></tr> |
|
146 </table> |
|
147 |
|
148 <a NAME="CircuitPythonUpdaterInterface.__init__" ID="CircuitPythonUpdaterInterface.__init__"></a> |
|
149 <h4>CircuitPythonUpdaterInterface (Constructor)</h4> |
|
150 <b>CircuitPythonUpdaterInterface</b>(<i>device, parent=None</i>) |
|
151 |
|
152 <p> |
|
153 Constructor |
|
154 </p> |
|
155 <dl> |
|
156 |
|
157 <dt><i>device</i> (CircuitPythonDevice)</dt> |
|
158 <dd> |
|
159 reference to the CircuitPython device interface |
|
160 </dd> |
|
161 <dt><i>parent</i> (QObject (optional))</dt> |
|
162 <dd> |
|
163 reference to the parent object (defaults to None) |
|
164 </dd> |
|
165 </dl> |
|
166 <a NAME="CircuitPythonUpdaterInterface.__aboutCircup" ID="CircuitPythonUpdaterInterface.__aboutCircup"></a> |
|
167 <h4>CircuitPythonUpdaterInterface.__aboutCircup</h4> |
|
168 <b>__aboutCircup</b>(<i></i>) |
|
169 |
|
170 <p> |
|
171 Private slot to show some info about 'circup'. |
|
172 </p> |
|
173 <a NAME="CircuitPythonUpdaterInterface.__addBundle" ID="CircuitPythonUpdaterInterface.__addBundle"></a> |
|
174 <h4>CircuitPythonUpdaterInterface.__addBundle</h4> |
|
175 <b>__addBundle</b>(<i></i>) |
|
176 |
|
177 <p> |
|
178 Private slot to add a bundle to the local bundles list, by "user/repo" github |
|
179 string. |
|
180 </p> |
|
181 <a NAME="CircuitPythonUpdaterInterface.__doUpdateModules" ID="CircuitPythonUpdaterInterface.__doUpdateModules"></a> |
|
182 <h4>CircuitPythonUpdaterInterface.__doUpdateModules</h4> |
|
183 <b>__doUpdateModules</b>(<i>modules</i>) |
|
184 |
|
185 <p> |
|
186 Private method to perform the update of a list of modules. |
|
187 </p> |
|
188 <dl> |
|
189 |
|
190 <dt><i>modules</i> (circup.Module)</dt> |
|
191 <dd> |
|
192 list of modules to be updated |
|
193 </dd> |
|
194 </dl> |
|
195 <a NAME="CircuitPythonUpdaterInterface.__generateRequirements" ID="CircuitPythonUpdaterInterface.__generateRequirements"></a> |
|
196 <h4>CircuitPythonUpdaterInterface.__generateRequirements</h4> |
|
197 <b>__generateRequirements</b>(<i></i>) |
|
198 |
|
199 <p> |
|
200 Private slot to generate requirements for the connected device. |
|
201 </p> |
|
202 <a NAME="CircuitPythonUpdaterInterface.__installFromAvailable" ID="CircuitPythonUpdaterInterface.__installFromAvailable"></a> |
|
203 <h4>CircuitPythonUpdaterInterface.__installFromAvailable</h4> |
|
204 <b>__installFromAvailable</b>(<i></i>) |
|
205 |
|
206 <p> |
|
207 Private slot to install modules onto the connected device. |
|
208 </p> |
|
209 <a NAME="CircuitPythonUpdaterInterface.__installFromCode" ID="CircuitPythonUpdaterInterface.__installFromCode"></a> |
|
210 <h4>CircuitPythonUpdaterInterface.__installFromCode</h4> |
|
211 <b>__installFromCode</b>(<i></i>) |
|
212 |
|
213 <p> |
|
214 Private slot to install modules based on the 'code.py' file of the |
|
215 connected device. |
|
216 </p> |
|
217 <a NAME="CircuitPythonUpdaterInterface.__installModules" ID="CircuitPythonUpdaterInterface.__installModules"></a> |
|
218 <h4>CircuitPythonUpdaterInterface.__installModules</h4> |
|
219 <b>__installModules</b>(<i>installs</i>) |
|
220 |
|
221 <p> |
|
222 Private method to install the given list of modules. |
|
223 </p> |
|
224 <dl> |
|
225 |
|
226 <dt><i>installs</i> (list of str)</dt> |
|
227 <dd> |
|
228 list of module names to be installed |
|
229 </dd> |
|
230 </dl> |
|
231 <a NAME="CircuitPythonUpdaterInterface.__installRequirements" ID="CircuitPythonUpdaterInterface.__installRequirements"></a> |
|
232 <h4>CircuitPythonUpdaterInterface.__installRequirements</h4> |
|
233 <b>__installRequirements</b>(<i></i>) |
|
234 |
|
235 <p> |
|
236 Private slot to install modules determined by a requirements file. |
|
237 </p> |
|
238 <a NAME="CircuitPythonUpdaterInterface.__listOutdatedModules" ID="CircuitPythonUpdaterInterface.__listOutdatedModules"></a> |
|
239 <h4>CircuitPythonUpdaterInterface.__listOutdatedModules</h4> |
|
240 <b>__listOutdatedModules</b>(<i></i>) |
|
241 |
|
242 <p> |
|
243 Private slot to list the outdated modules of the connected device. |
|
244 </p> |
|
245 <a NAME="CircuitPythonUpdaterInterface.__removeBundle" ID="CircuitPythonUpdaterInterface.__removeBundle"></a> |
|
246 <h4>CircuitPythonUpdaterInterface.__removeBundle</h4> |
|
247 <b>__removeBundle</b>(<i></i>) |
|
248 |
|
249 <p> |
|
250 Private slot to remove one or more bundles from the local bundles list. |
|
251 </p> |
|
252 <a NAME="CircuitPythonUpdaterInterface.__showAvailableModules" ID="CircuitPythonUpdaterInterface.__showAvailableModules"></a> |
|
253 <h4>CircuitPythonUpdaterInterface.__showAvailableModules</h4> |
|
254 <b>__showAvailableModules</b>(<i></i>) |
|
255 |
|
256 <p> |
|
257 Private slot to show the available modules. |
|
258 </p> |
|
259 <p> |
|
260 These are modules which could be installed on the device. |
|
261 </p> |
|
262 <a NAME="CircuitPythonUpdaterInterface.__showBundles" ID="CircuitPythonUpdaterInterface.__showBundles"></a> |
|
263 <h4>CircuitPythonUpdaterInterface.__showBundles</h4> |
|
264 <b>__showBundles</b>(<i>withModules=False</i>) |
|
265 |
|
266 <p> |
|
267 Private slot to show the available bundles (default and local). |
|
268 </p> |
|
269 <dl> |
|
270 |
|
271 <dt><i>withModules</i> (bool (optional))</dt> |
|
272 <dd> |
|
273 flag indicating to list the modules and their version |
|
274 (defaults to False) |
|
275 </dd> |
|
276 </dl> |
|
277 <a NAME="CircuitPythonUpdaterInterface.__showBundlesModules" ID="CircuitPythonUpdaterInterface.__showBundlesModules"></a> |
|
278 <h4>CircuitPythonUpdaterInterface.__showBundlesModules</h4> |
|
279 <b>__showBundlesModules</b>(<i></i>) |
|
280 |
|
281 <p> |
|
282 Private slot to show the available bundles (default and local) with their |
|
283 modules. |
|
284 </p> |
|
285 <a NAME="CircuitPythonUpdaterInterface.__showInstalledModules" ID="CircuitPythonUpdaterInterface.__showInstalledModules"></a> |
|
286 <h4>CircuitPythonUpdaterInterface.__showInstalledModules</h4> |
|
287 <b>__showInstalledModules</b>(<i></i>) |
|
288 |
|
289 <p> |
|
290 Private slot to show the modules installed on the connected device. |
|
291 </p> |
|
292 <a NAME="CircuitPythonUpdaterInterface.__uninstallModules" ID="CircuitPythonUpdaterInterface.__uninstallModules"></a> |
|
293 <h4>CircuitPythonUpdaterInterface.__uninstallModules</h4> |
|
294 <b>__uninstallModules</b>(<i></i>) |
|
295 |
|
296 <p> |
|
297 Private slot to uninstall modules from the connected device. |
|
298 </p> |
|
299 <a NAME="CircuitPythonUpdaterInterface.__updateAllModules" ID="CircuitPythonUpdaterInterface.__updateAllModules"></a> |
|
300 <h4>CircuitPythonUpdaterInterface.__updateAllModules</h4> |
|
301 <b>__updateAllModules</b>(<i></i>) |
|
302 |
|
303 <p> |
|
304 Private slot to update all modules of the connected device. |
|
305 </p> |
|
306 <a NAME="CircuitPythonUpdaterInterface.__updateModules" ID="CircuitPythonUpdaterInterface.__updateModules"></a> |
|
307 <h4>CircuitPythonUpdaterInterface.__updateModules</h4> |
|
308 <b>__updateModules</b>(<i></i>) |
|
309 |
|
310 <p> |
|
311 Private slot to update the modules of the connected device. |
|
312 </p> |
|
313 <a NAME="CircuitPythonUpdaterInterface.installCircup" ID="CircuitPythonUpdaterInterface.installCircup"></a> |
|
314 <h4>CircuitPythonUpdaterInterface.installCircup</h4> |
|
315 <b>installCircup</b>(<i></i>) |
|
316 |
|
317 <p> |
|
318 Public slot to install the 'circup' package via pip. |
|
319 </p> |
|
320 <a NAME="CircuitPythonUpdaterInterface.populateMenu" ID="CircuitPythonUpdaterInterface.populateMenu"></a> |
|
321 <h4>CircuitPythonUpdaterInterface.populateMenu</h4> |
|
322 <b>populateMenu</b>(<i>menu</i>) |
|
323 |
|
324 <p> |
|
325 Public method to populate the 'circup' menu. |
|
326 </p> |
|
327 <dl> |
|
328 |
|
329 <dt><i>menu</i> (QMenu)</dt> |
|
330 <dd> |
|
331 reference to the menu to be populated |
|
332 </dd> |
|
333 </dl> |
|
334 <div align="right"><a href="#top">Up</a></div> |
|
335 <hr /> |
|
336 <hr /> |
|
337 <a NAME="isCircupAvailable" ID="isCircupAvailable"></a> |
|
338 <h2>isCircupAvailable</h2> |
|
339 <b>isCircupAvailable</b>(<i></i>) |
|
340 |
|
341 <p> |
|
342 Function to check for the availability of 'circup'. |
|
343 </p> |
|
344 <dl> |
|
345 <dt>Return:</dt> |
|
346 <dd> |
|
347 flag indicating the availability of 'circup' |
|
348 </dd> |
|
349 </dl> |
|
350 <dl> |
|
351 <dt>Return Type:</dt> |
|
352 <dd> |
|
353 bool |
|
354 </dd> |
|
355 </dl> |
|
356 <div align="right"><a href="#top">Up</a></div> |
|
357 <hr /> |
|
358 </body></html> |