mirror of
https://github.com/naruxde/revpipycontrol.git
synced 2025-11-08 15:43:52 +01:00
Sicherheitswarnung vor dem Output schreiben integriert
Hauptfenster alles aufr?umen vor destroy() Wertepr?fung bei RevPiCheckClient int() Werten Bearbeitungsfunktion bei RevPiCheckClient eingebaut Hilfemen? mit Webbrowser aufruf eingebaut
This commit is contained in:
@@ -6,3 +6,4 @@ revpipycontrol.egg-info/*
|
||||
deb/*
|
||||
.eric6project/*
|
||||
*.directory
|
||||
*.mo
|
||||
|
||||
@@ -10,7 +10,7 @@ revpicheckclient</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>None</td></tr>
|
||||
<tr><td>_</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -35,7 +35,7 @@ tkinter.Frame
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Class Attributes</h3>
|
||||
<table>
|
||||
<tr><td>cli</td></tr><tr><td>tk</td></tr>
|
||||
<tr><td>None</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Class Methods</h3>
|
||||
@@ -49,11 +49,20 @@ Methods</h3>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__init__">RevPiCheckClient</a></td>
|
||||
<td>Instantiiert MyApp-Klasse.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__chval">__chval</a></td>
|
||||
<td>Schreibt neuen Output Wert auf den RevPi.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__hidewin">__hidewin</a></td>
|
||||
<td></td>
|
||||
<td>Verbergt übergebenes Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__saveoldvalue">__saveoldvalue</a></td>
|
||||
<td>Speichert bei Keypress aktuellen Wert für wiederherstellung.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__showwin">__showwin</a></td>
|
||||
<td></td>
|
||||
<td>Zeigt oder verbergt übergebenes Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.__spinboxkey">__spinboxkey</a></td>
|
||||
<td>Prüft die Eingabe auf plausibilität.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._createiogroup">_createiogroup</a></td>
|
||||
<td>Erstellt IO-Gruppen.</td>
|
||||
@@ -61,20 +70,35 @@ Methods</h3>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._createwidgets">_createwidgets</a></td>
|
||||
<td>Erstellt den Fensterinhalt.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._readvalues">_readvalues</a></td>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._onfrmconf">_onfrmconf</a></td>
|
||||
<td>Erstellt Fenster in einem Canvas.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._warnwrite">_warnwrite</a></td>
|
||||
<td>Warnung für Benutzer über Schreibfunktion einmal fragen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient._workvalues">_workvalues</a></td>
|
||||
<td>Alle Werte der Inputs und Outputs abrufen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.chval">chval</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.onfrmconf">onfrmconf</a></td>
|
||||
<td></td>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.hideallwindows">hideallwindows</a></td>
|
||||
<td>Versteckt alle Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.readvalues">readvalues</a></td>
|
||||
<td></td>
|
||||
<td>Ruft nur Input Werte von RevPi ab und aktualisiert Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.refreshvalues">refreshvalues</a></td>
|
||||
<td>Ruft alle IO Werte von RevPi ab und aktualisiert Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.toggleauto">toggleauto</a></td>
|
||||
<td></td>
|
||||
<td>Schaltet zwischen Autorefresh um und aktualisiert Widgets.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.togglewrite">togglewrite</a></td>
|
||||
<td>Schaltet zwischen DoWrite um und aktiviert Schreibfunktion.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.validatereturn">validatereturn</a></td>
|
||||
<td>Überprüft die Rückgaben der setvalue Funktion.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiCheckClient.writevalues">writevalues</a></td>
|
||||
<td>Schreibt geänderte Outputs auf den RevPi.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
@@ -88,49 +112,147 @@ RevPiCheckClient (Constructor)</h3>
|
||||
<b>RevPiCheckClient</b>(<i>master, xmlcli, xmlmode=0</i>)
|
||||
<p>
|
||||
Instantiiert MyApp-Klasse.
|
||||
</p><a NAME="RevPiCheckClient.__chval" ID="RevPiCheckClient.__chval"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.__chval</h3>
|
||||
<b>__chval</b>(<i>device, io, event=None</i>)
|
||||
<p>
|
||||
Schreibt neuen Output Wert auf den RevPi.
|
||||
</p><a NAME="RevPiCheckClient.__hidewin" ID="RevPiCheckClient.__hidewin"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.__hidewin</h3>
|
||||
<b>__hidewin</b>(<i>win, event=None</i>)
|
||||
<a NAME="RevPiCheckClient.__showwin" ID="RevPiCheckClient.__showwin"></a>
|
||||
<p>
|
||||
Verbergt übergebenes Fenster.
|
||||
</p><dl>
|
||||
<dt><i>win:</i></dt>
|
||||
<dd>
|
||||
Fenster zum verbergen
|
||||
</dd><dt><i>event:</i></dt>
|
||||
<dd>
|
||||
Tkinter Event
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient.__saveoldvalue" ID="RevPiCheckClient.__saveoldvalue"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.__saveoldvalue</h3>
|
||||
<b>__saveoldvalue</b>(<i>event, tkvar</i>)
|
||||
<p>
|
||||
Speichert bei Keypress aktuellen Wert für wiederherstellung.
|
||||
</p><a NAME="RevPiCheckClient.__showwin" ID="RevPiCheckClient.__showwin"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.__showwin</h3>
|
||||
<b>__showwin</b>(<i>win</i>)
|
||||
<a NAME="RevPiCheckClient._createiogroup" ID="RevPiCheckClient._createiogroup"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient._createiogroup</h3>
|
||||
<b>_createiogroup</b>(<i>device, frame, iotype</i>)
|
||||
<p>
|
||||
Erstellt IO-Gruppen.
|
||||
</p><a NAME="RevPiCheckClient._createwidgets" ID="RevPiCheckClient._createwidgets"></a>
|
||||
Zeigt oder verbergt übergebenes Fenster.
|
||||
</p><dl>
|
||||
<dt><i>win:</i></dt>
|
||||
<dd>
|
||||
Fenster zum anzeigen/verbergen
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient.__spinboxkey" ID="RevPiCheckClient.__spinboxkey"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.__spinboxkey</h3>
|
||||
<b>__spinboxkey</b>(<i>device, io, event=None</i>)
|
||||
<p>
|
||||
Prüft die Eingabe auf plausibilität.
|
||||
</p><dl>
|
||||
<dt><i>event:</i></dt>
|
||||
<dd>
|
||||
tkinter Event
|
||||
</dd><dt><i>io:</i></dt>
|
||||
<dd>
|
||||
IO Liste mit tkinter Variable
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient._createwidgets" ID="RevPiCheckClient._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient._createwidgets</h3>
|
||||
<b>_createwidgets</b>(<i></i>)
|
||||
<p>
|
||||
Erstellt den Fensterinhalt.
|
||||
</p><a NAME="RevPiCheckClient._readvalues" ID="RevPiCheckClient._readvalues"></a>
|
||||
</p><a NAME="RevPiCheckClient._onfrmconf" ID="RevPiCheckClient._onfrmconf"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient._readvalues</h3>
|
||||
<b>_readvalues</b>(<i></i>)
|
||||
RevPiCheckClient._onfrmconf</h3>
|
||||
<b>_onfrmconf</b>(<i>canvas</i>)
|
||||
<p>
|
||||
Erstellt Fenster in einem Canvas.
|
||||
</p><dl>
|
||||
<dt><i>canvas:</i></dt>
|
||||
<dd>
|
||||
Canvas in dem Objekte erstellt werden sollen
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient._warnwrite" ID="RevPiCheckClient._warnwrite"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient._warnwrite</h3>
|
||||
<b>_warnwrite</b>(<i></i>)
|
||||
<p>
|
||||
Warnung für Benutzer über Schreibfunktion einmal fragen.
|
||||
</p><dl>
|
||||
<dt>Returns:</dt>
|
||||
<dd>
|
||||
True, wenn Warnung einmal mit OK bestätigt wurde
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient._workvalues" ID="RevPiCheckClient._workvalues"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient._workvalues</h3>
|
||||
<b>_workvalues</b>(<i>io_dicts=None, writeout=False</i>)
|
||||
<p>
|
||||
Alle Werte der Inputs und Outputs abrufen.
|
||||
</p><a NAME="RevPiCheckClient.chval" ID="RevPiCheckClient.chval"></a>
|
||||
</p><dl>
|
||||
<dt><i>io_dicts:</i></dt>
|
||||
<dd>
|
||||
Arbeit nur für dieses Dict()
|
||||
</dd><dt><i>writeout:</i></dt>
|
||||
<dd>
|
||||
Änderungen auf RevPi schreiben
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient.hideallwindows" ID="RevPiCheckClient.hideallwindows"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.chval</h3>
|
||||
<b>chval</b>(<i>device, io</i>)
|
||||
<a NAME="RevPiCheckClient.onfrmconf" ID="RevPiCheckClient.onfrmconf"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.onfrmconf</h3>
|
||||
<b>onfrmconf</b>(<i>canvas</i>)
|
||||
<a NAME="RevPiCheckClient.readvalues" ID="RevPiCheckClient.readvalues"></a>
|
||||
RevPiCheckClient.hideallwindows</h3>
|
||||
<b>hideallwindows</b>(<i></i>)
|
||||
<p>
|
||||
Versteckt alle Fenster.
|
||||
</p><a NAME="RevPiCheckClient.readvalues" ID="RevPiCheckClient.readvalues"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.readvalues</h3>
|
||||
<b>readvalues</b>(<i></i>)
|
||||
<a NAME="RevPiCheckClient.toggleauto" ID="RevPiCheckClient.toggleauto"></a>
|
||||
<p>
|
||||
Ruft nur Input Werte von RevPi ab und aktualisiert Fenster.
|
||||
</p><a NAME="RevPiCheckClient.refreshvalues" ID="RevPiCheckClient.refreshvalues"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.refreshvalues</h3>
|
||||
<b>refreshvalues</b>(<i></i>)
|
||||
<p>
|
||||
Ruft alle IO Werte von RevPi ab und aktualisiert Fenster.
|
||||
</p><a NAME="RevPiCheckClient.toggleauto" ID="RevPiCheckClient.toggleauto"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.toggleauto</h3>
|
||||
<b>toggleauto</b>(<i></i>)
|
||||
|
||||
<p>
|
||||
Schaltet zwischen Autorefresh um und aktualisiert Widgets.
|
||||
</p><a NAME="RevPiCheckClient.togglewrite" ID="RevPiCheckClient.togglewrite"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.togglewrite</h3>
|
||||
<b>togglewrite</b>(<i></i>)
|
||||
<p>
|
||||
Schaltet zwischen DoWrite um und aktiviert Schreibfunktion.
|
||||
</p><a NAME="RevPiCheckClient.validatereturn" ID="RevPiCheckClient.validatereturn"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.validatereturn</h3>
|
||||
<b>validatereturn</b>(<i>returnlist</i>)
|
||||
<p>
|
||||
Überprüft die Rückgaben der setvalue Funktion.
|
||||
</p><dl>
|
||||
<dt><i>returnlist:</i></dt>
|
||||
<dd>
|
||||
list() der xml Rückgabe
|
||||
</dd>
|
||||
</dl><a NAME="RevPiCheckClient.writevalues" ID="RevPiCheckClient.writevalues"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiCheckClient.writevalues</h3>
|
||||
<b>writevalues</b>(<i></i>)
|
||||
<p>
|
||||
Schreibt geänderte Outputs auf den RevPi.
|
||||
</p>
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr />
|
||||
</body></html>
|
||||
@@ -10,7 +10,7 @@ revpilogfile</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>None</td></tr>
|
||||
<tr><td>_</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -47,28 +47,28 @@ Methods</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.__init__">RevPiLogfile</a></td>
|
||||
<td>Init RevPiLogfile-Class.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile._closewin">_closewin</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile._createwidgets">_createwidgets</a></td>
|
||||
<td></td>
|
||||
<td>Erstellt alle Widgets.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile._load_log">_load_log</a></td>
|
||||
<td>Läd die angegebenen Logfiles herunter.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.btn_clearapp">btn_clearapp</a></td>
|
||||
<td></td>
|
||||
<td>Leert die Logliste der App.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.btn_clearplc">btn_clearplc</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.get_applines">get_applines</a></td>
|
||||
<td></td>
|
||||
<td>Leert die Logliste des PLC.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.get_applog">get_applog</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.get_plclines">get_plclines</a></td>
|
||||
<td></td>
|
||||
<td>Ruft App Logbuch ab.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiLogfile.get_plclog">get_plclog</a></td>
|
||||
<td></td>
|
||||
<td>Ruft PLC Logbuch ab.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
@@ -80,35 +80,78 @@ Static Methods</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile (Constructor)</h3>
|
||||
<b>RevPiLogfile</b>(<i>master, xmlcli</i>)
|
||||
<p>
|
||||
Init RevPiLogfile-Class.
|
||||
</p><a NAME="RevPiLogfile._closewin" ID="RevPiLogfile._closewin"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile._closewin</h3>
|
||||
<b>_closewin</b>(<i>event</i>)
|
||||
<a NAME="RevPiLogfile._createwidgets" ID="RevPiLogfile._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile._createwidgets</h3>
|
||||
<b>_createwidgets</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.btn_clearapp" ID="RevPiLogfile.btn_clearapp"></a>
|
||||
<p>
|
||||
Erstellt alle Widgets.
|
||||
</p><a NAME="RevPiLogfile._load_log" ID="RevPiLogfile._load_log"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile._load_log</h3>
|
||||
<b>_load_log</b>(<i>textwidget, xmlcall, startposition, full</i>)
|
||||
<p>
|
||||
Läd die angegebenen Logfiles herunter.
|
||||
</p><dl>
|
||||
<dt><i>textwidget:</i></dt>
|
||||
<dd>
|
||||
Widget in das Logs eingefügt werden sollen
|
||||
</dd><dt><i>xmlcall:</i></dt>
|
||||
<dd>
|
||||
xmlrpc Funktion zum Abrufen der Logdaten
|
||||
</dd><dt><i>startposition:</i></dt>
|
||||
<dd>
|
||||
Startposition ab der Logdaten kommen sollen
|
||||
</dd><dt><i>full:</i></dt>
|
||||
<dd>
|
||||
Komplettes Logbuch laden
|
||||
</dd>
|
||||
</dl><dl>
|
||||
<dt>Returns:</dt>
|
||||
<dd>
|
||||
Ende der Datei (neue Startposition)
|
||||
</dd>
|
||||
</dl><a NAME="RevPiLogfile.btn_clearapp" ID="RevPiLogfile.btn_clearapp"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.btn_clearapp</h3>
|
||||
<b>btn_clearapp</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.btn_clearplc" ID="RevPiLogfile.btn_clearplc"></a>
|
||||
<p>
|
||||
Leert die Logliste der App.
|
||||
</p><a NAME="RevPiLogfile.btn_clearplc" ID="RevPiLogfile.btn_clearplc"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.btn_clearplc</h3>
|
||||
<b>btn_clearplc</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.get_applines" ID="RevPiLogfile.get_applines"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.get_applines</h3>
|
||||
<b>get_applines</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.get_applog" ID="RevPiLogfile.get_applog"></a>
|
||||
<p>
|
||||
Leert die Logliste des PLC.
|
||||
</p><a NAME="RevPiLogfile.get_applog" ID="RevPiLogfile.get_applog"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.get_applog</h3>
|
||||
<b>get_applog</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.get_plclines" ID="RevPiLogfile.get_plclines"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.get_plclines</h3>
|
||||
<b>get_plclines</b>(<i></i>)
|
||||
<a NAME="RevPiLogfile.get_plclog" ID="RevPiLogfile.get_plclog"></a>
|
||||
<b>get_applog</b>(<i>full=False</i>)
|
||||
<p>
|
||||
Ruft App Logbuch ab.
|
||||
</p><dl>
|
||||
<dt><i>full:</i></dt>
|
||||
<dd>
|
||||
Ganzes Logbuch laden
|
||||
</dd>
|
||||
</dl><a NAME="RevPiLogfile.get_plclog" ID="RevPiLogfile.get_plclog"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiLogfile.get_plclog</h3>
|
||||
<b>get_plclog</b>(<i></i>)
|
||||
|
||||
<b>get_plclog</b>(<i>full=False</i>)
|
||||
<p>
|
||||
Ruft PLC Logbuch ab.
|
||||
</p><dl>
|
||||
<dt><i>full:</i></dt>
|
||||
<dd>
|
||||
Ganzes Logbuch laden
|
||||
</dd>
|
||||
</dl>
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr />
|
||||
</body></html>
|
||||
@@ -10,7 +10,7 @@ revpioption</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>None</td></tr>
|
||||
<tr><td>_</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -47,22 +47,28 @@ Methods</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption.__init__">RevPiOption</a></td>
|
||||
<td></td>
|
||||
<td>Init RevPiOption-Class.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption._changesdone">_changesdone</a></td>
|
||||
<td>Prüft ob sich die Einstellungen geändert haben.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption._checkclose">_checkclose</a></td>
|
||||
<td>Prüft ob Fenster beendet werden soll.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption._createwidgets">_createwidgets</a></td>
|
||||
<td></td>
|
||||
<td>Erstellt Widgets.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption._loadappdata">_loadappdata</a></td>
|
||||
<td></td>
|
||||
<td>Läd aktuelle Einstellungen vom RevPi.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption._setappdata">_setappdata</a></td>
|
||||
<td></td>
|
||||
<td>Speichert geänderte Einstellungen auf RevPi.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption.askxmlon">askxmlon</a></td>
|
||||
<td></td>
|
||||
<td>Fragt Nuter, ob wirklicht abgeschaltet werden soll.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiOption.xmlmods">xmlmods</a></td>
|
||||
<td></td>
|
||||
<td>Passt XML-Optionszugriff an.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
@@ -74,27 +80,66 @@ Static Methods</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption (Constructor)</h3>
|
||||
<b>RevPiOption</b>(<i>master, xmlcli, xmlmode</i>)
|
||||
<a NAME="RevPiOption._createwidgets" ID="RevPiOption._createwidgets"></a>
|
||||
<p>
|
||||
Init RevPiOption-Class.
|
||||
</p><dl>
|
||||
<dt>Returns:</dt>
|
||||
<dd>
|
||||
None
|
||||
</dd>
|
||||
</dl><a NAME="RevPiOption._changesdone" ID="RevPiOption._changesdone"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption._changesdone</h3>
|
||||
<b>_changesdone</b>(<i></i>)
|
||||
<p>
|
||||
Prüft ob sich die Einstellungen geändert haben.
|
||||
</p><dl>
|
||||
<dt>Returns:</dt>
|
||||
<dd>
|
||||
True, wenn min. eine Einstellung geändert wurde
|
||||
</dd>
|
||||
</dl><a NAME="RevPiOption._checkclose" ID="RevPiOption._checkclose"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption._checkclose</h3>
|
||||
<b>_checkclose</b>(<i>event=None</i>)
|
||||
<p>
|
||||
Prüft ob Fenster beendet werden soll.
|
||||
</p><dl>
|
||||
<dt><i>event:</i></dt>
|
||||
<dd>
|
||||
tkinter-Event
|
||||
</dd>
|
||||
</dl><a NAME="RevPiOption._createwidgets" ID="RevPiOption._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption._createwidgets</h3>
|
||||
<b>_createwidgets</b>(<i></i>)
|
||||
<a NAME="RevPiOption._loadappdata" ID="RevPiOption._loadappdata"></a>
|
||||
<p>
|
||||
Erstellt Widgets.
|
||||
</p><a NAME="RevPiOption._loadappdata" ID="RevPiOption._loadappdata"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption._loadappdata</h3>
|
||||
<b>_loadappdata</b>(<i></i>)
|
||||
<a NAME="RevPiOption._setappdata" ID="RevPiOption._setappdata"></a>
|
||||
<p>
|
||||
Läd aktuelle Einstellungen vom RevPi.
|
||||
</p><a NAME="RevPiOption._setappdata" ID="RevPiOption._setappdata"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption._setappdata</h3>
|
||||
<b>_setappdata</b>(<i></i>)
|
||||
<a NAME="RevPiOption.askxmlon" ID="RevPiOption.askxmlon"></a>
|
||||
<p>
|
||||
Speichert geänderte Einstellungen auf RevPi.
|
||||
</p><a NAME="RevPiOption.askxmlon" ID="RevPiOption.askxmlon"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption.askxmlon</h3>
|
||||
<b>askxmlon</b>(<i></i>)
|
||||
<a NAME="RevPiOption.xmlmods" ID="RevPiOption.xmlmods"></a>
|
||||
<p>
|
||||
Fragt Nuter, ob wirklicht abgeschaltet werden soll.
|
||||
</p><a NAME="RevPiOption.xmlmods" ID="RevPiOption.xmlmods"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiOption.xmlmods</h3>
|
||||
<b>xmlmods</b>(<i></i>)
|
||||
|
||||
<p>
|
||||
Passt XML-Optionszugriff an.
|
||||
</p>
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr />
|
||||
</body></html>
|
||||
@@ -10,7 +10,7 @@ revpiplclist</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>savefile</td></tr>
|
||||
<tr><td>_</td></tr><tr><td>savefile</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -52,6 +52,9 @@ Methods</h3>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList.__init__">RevPiPlcList</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList._checkclose">_checkclose</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList._createwidgets">_createwidgets</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
@@ -67,9 +70,6 @@ Methods</h3>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList.evt_btnadd">evt_btnadd</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList.evt_btnclose">evt_btnclose</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPlcList.evt_btnnew">evt_btnnew</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
@@ -95,6 +95,10 @@ Static Methods</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList (Constructor)</h3>
|
||||
<b>RevPiPlcList</b>(<i>master</i>)
|
||||
<a NAME="RevPiPlcList._checkclose" ID="RevPiPlcList._checkclose"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList._checkclose</h3>
|
||||
<b>_checkclose</b>(<i>event=None</i>)
|
||||
<a NAME="RevPiPlcList._createwidgets" ID="RevPiPlcList._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList._createwidgets</h3>
|
||||
@@ -115,10 +119,6 @@ RevPiPlcList.build_listconn</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList.evt_btnadd</h3>
|
||||
<b>evt_btnadd</b>(<i></i>)
|
||||
<a NAME="RevPiPlcList.evt_btnclose" ID="RevPiPlcList.evt_btnclose"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList.evt_btnclose</h3>
|
||||
<b>evt_btnclose</b>(<i></i>)
|
||||
<a NAME="RevPiPlcList.evt_btnnew" ID="RevPiPlcList.evt_btnnew"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPlcList.evt_btnnew</h3>
|
||||
|
||||
@@ -10,7 +10,7 @@ revpiprogram</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>savefile</td></tr>
|
||||
<tr><td>_</td></tr><tr><td>savefile</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -35,7 +35,7 @@ tkinter.Frame
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Class Attributes</h3>
|
||||
<table>
|
||||
<tr><td>myapp</td></tr><tr><td>root</td></tr>
|
||||
<tr><td>None</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Class Methods</h3>
|
||||
@@ -47,6 +47,9 @@ Methods</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.__init__">RevPiProgram</a></td>
|
||||
<td>Init RevPiProgram-Class.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram._checkclose">_checkclose</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram._createwidgets">_createwidgets</a></td>
|
||||
@@ -71,22 +74,22 @@ Methods</h3>
|
||||
<td>Erstellt eine Dateiliste von einem Verzeichnis.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.getpictoryrsc">getpictoryrsc</a></td>
|
||||
<td></td>
|
||||
<td>Läd die piCtory Konfiguration herunter.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.getprocimg">getprocimg</a></td>
|
||||
<td></td>
|
||||
<td>Läd das aktuelle Prozessabbild herunter.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.picontrolreset">picontrolreset</a></td>
|
||||
<td></td>
|
||||
<td>Fürt ein Reset der piBridge durch.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.plcdownload">plcdownload</a></td>
|
||||
<td></td>
|
||||
<td>Läd das aktuelle Projekt herunter.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.plcupload">plcupload</a></td>
|
||||
<td></td>
|
||||
<td>Lädt das angegebene Projekt auf den RevPi.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiProgram.setpictoryrsc">setpictoryrsc</a></td>
|
||||
<td></td>
|
||||
<td>Überträgt die angegebene piCtory-Konfiguration.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
@@ -98,6 +101,12 @@ Static Methods</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram (Constructor)</h3>
|
||||
<b>RevPiProgram</b>(<i>master, xmlcli, xmlmode, revpi</i>)
|
||||
<p>
|
||||
Init RevPiProgram-Class.
|
||||
</p><a NAME="RevPiProgram._checkclose" ID="RevPiProgram._checkclose"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram._checkclose</h3>
|
||||
<b>_checkclose</b>(<i>event=None</i>)
|
||||
<a NAME="RevPiProgram._createwidgets" ID="RevPiProgram._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram._createwidgets</h3>
|
||||
@@ -130,7 +139,7 @@ RevPiProgram.check_replacedir</h3>
|
||||
Gibt das rootdir von einem entpackten Verzeichnis zurueck.
|
||||
</p><p>
|
||||
Dabei wird geprueft, ob es sich um einen einzelnen Ordner handelt
|
||||
und ob es eine piCtory Konfiguraiton im rootdir gibt.
|
||||
und ob es eine piCtory Konfiguration im rootdir gibt.
|
||||
</p><dl>
|
||||
<dt><i>rootdir:</i></dt>
|
||||
<dd>
|
||||
@@ -161,27 +170,39 @@ Dateiliste
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.getpictoryrsc</h3>
|
||||
<b>getpictoryrsc</b>(<i></i>)
|
||||
<a NAME="RevPiProgram.getprocimg" ID="RevPiProgram.getprocimg"></a>
|
||||
<p>
|
||||
Läd die piCtory Konfiguration herunter.
|
||||
</p><a NAME="RevPiProgram.getprocimg" ID="RevPiProgram.getprocimg"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.getprocimg</h3>
|
||||
<b>getprocimg</b>(<i></i>)
|
||||
<a NAME="RevPiProgram.picontrolreset" ID="RevPiProgram.picontrolreset"></a>
|
||||
<p>
|
||||
Läd das aktuelle Prozessabbild herunter.
|
||||
</p><a NAME="RevPiProgram.picontrolreset" ID="RevPiProgram.picontrolreset"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.picontrolreset</h3>
|
||||
<b>picontrolreset</b>(<i></i>)
|
||||
<a NAME="RevPiProgram.plcdownload" ID="RevPiProgram.plcdownload"></a>
|
||||
<p>
|
||||
Fürt ein Reset der piBridge durch.
|
||||
</p><a NAME="RevPiProgram.plcdownload" ID="RevPiProgram.plcdownload"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.plcdownload</h3>
|
||||
<b>plcdownload</b>(<i></i>)
|
||||
<a NAME="RevPiProgram.plcupload" ID="RevPiProgram.plcupload"></a>
|
||||
<p>
|
||||
Läd das aktuelle Projekt herunter.
|
||||
</p><a NAME="RevPiProgram.plcupload" ID="RevPiProgram.plcupload"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.plcupload</h3>
|
||||
<b>plcupload</b>(<i></i>)
|
||||
<a NAME="RevPiProgram.setpictoryrsc" ID="RevPiProgram.setpictoryrsc"></a>
|
||||
<p>
|
||||
Lädt das angegebene Projekt auf den RevPi.
|
||||
</p><a NAME="RevPiProgram.setpictoryrsc" ID="RevPiProgram.setpictoryrsc"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiProgram.setpictoryrsc</h3>
|
||||
<b>setpictoryrsc</b>(<i>filename=None</i>)
|
||||
|
||||
<p>
|
||||
Überträgt die angegebene piCtory-Konfiguration.
|
||||
</p>
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr />
|
||||
</body></html>
|
||||
@@ -10,7 +10,7 @@ revpipycontrol</h1>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Global Attributes</h3>
|
||||
<table>
|
||||
<tr><td>None</td></tr>
|
||||
<tr><td>_</td></tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Classes</h3>
|
||||
@@ -23,10 +23,7 @@ Classes</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
Functions</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a style="color:#0000FF" href="#addroot">addroot</a></td>
|
||||
<td>Hängt root-dir der Anwendung vor Dateinamen.</td>
|
||||
</tr>
|
||||
<tr><td>None</td></tr>
|
||||
</table>
|
||||
<hr /><hr />
|
||||
<a NAME="RevPiPyControl" ID="RevPiPyControl"></a>
|
||||
@@ -50,55 +47,67 @@ Methods</h3>
|
||||
<table>
|
||||
<tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.__init__">RevPiPyControl</a></td>
|
||||
<td></td>
|
||||
<td>Init RevPiPyControl-Class.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._btnstate">_btnstate</a></td>
|
||||
<td></td>
|
||||
<td>Setzt den state der Buttons.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._closeall">_closeall</a></td>
|
||||
<td></td>
|
||||
<td>Schließt alle Fenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._closeapp">_closeapp</a></td>
|
||||
<td>Räumt auf und beendet Programm.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._createwidgets">_createwidgets</a></td>
|
||||
<td>Erstellt den Fensterinhalt.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._fillconnbar">_fillconnbar</a></td>
|
||||
<td></td>
|
||||
<td>Generiert Menüeinträge für Verbindungen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._fillmbar">_fillmbar</a></td>
|
||||
<td></td>
|
||||
<td>Generiert Menüeinträge.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl._opt_conn">_opt_conn</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.infowindow">infowindow</a></td>
|
||||
<td>Öffnet das Fenster für die Verbindungen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcdebug">plcdebug</a></td>
|
||||
<td>Baut den Debugframe und packt ihn.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plclist">plclist</a></td>
|
||||
<td></td>
|
||||
<td>Öffnet das Fenster für die Verbindungen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plclogs">plclogs</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcmonitor">plcmonitor</a></td>
|
||||
<td>Startet das Monitorfenster.</td>
|
||||
<td>Öffnet das Fenster für Logdateien.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcoptions">plcoptions</a></td>
|
||||
<td>Startet das Optionsfenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcprogram">plcprogram</a></td>
|
||||
<td></td>
|
||||
<td>Startet das Programmfenster.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcrestart">plcrestart</a></td>
|
||||
<td></td>
|
||||
<td>Startet das PLC Programm neu.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcstart">plcstart</a></td>
|
||||
<td></td>
|
||||
<td>Startet das PLC Programm.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.plcstop">plcstop</a></td>
|
||||
<td></td>
|
||||
<td>Beendet das PLC Programm.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.serverdisconnect">serverdisconnect</a></td>
|
||||
<td>Trennt eine bestehende Verbindung.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.servererror">servererror</a></td>
|
||||
<td>Setzt alles auf NULL.</td>
|
||||
<td>Setzt alles zurück für neue Verbindungen.</td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.tmr_plcrunning">tmr_plcrunning</a></td>
|
||||
<td></td>
|
||||
</tr><tr>
|
||||
<td><a style="color:#0000FF" href="#RevPiPyControl.visitwebsite">visitwebsite</a></td>
|
||||
<td>Öffnet auf dem System einen Webbrowser zur Projektseite.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
@@ -110,15 +119,37 @@ Static Methods</h3>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl (Constructor)</h3>
|
||||
<b>RevPiPyControl</b>(<i>master=None</i>)
|
||||
<a NAME="RevPiPyControl._btnstate" ID="RevPiPyControl._btnstate"></a>
|
||||
<p>
|
||||
Init RevPiPyControl-Class.
|
||||
</p><dl>
|
||||
<dt><i>master:</i></dt>
|
||||
<dd>
|
||||
tkinter master
|
||||
</dd>
|
||||
</dl><a NAME="RevPiPyControl._btnstate" ID="RevPiPyControl._btnstate"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._btnstate</h3>
|
||||
<b>_btnstate</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl._closeall" ID="RevPiPyControl._closeall"></a>
|
||||
<p>
|
||||
Setzt den state der Buttons.
|
||||
</p><a NAME="RevPiPyControl._closeall" ID="RevPiPyControl._closeall"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._closeall</h3>
|
||||
<b>_closeall</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl._createwidgets" ID="RevPiPyControl._createwidgets"></a>
|
||||
<p>
|
||||
Schließt alle Fenster.
|
||||
</p><a NAME="RevPiPyControl._closeapp" ID="RevPiPyControl._closeapp"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._closeapp</h3>
|
||||
<b>_closeapp</b>(<i>event=None</i>)
|
||||
<p>
|
||||
Räumt auf und beendet Programm.
|
||||
</p><dl>
|
||||
<dt><i>event:</i></dt>
|
||||
<dd>
|
||||
tkinter Event
|
||||
</dd>
|
||||
</dl><a NAME="RevPiPyControl._createwidgets" ID="RevPiPyControl._createwidgets"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._createwidgets</h3>
|
||||
<b>_createwidgets</b>(<i></i>)
|
||||
@@ -128,28 +159,42 @@ Erstellt den Fensterinhalt.
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._fillconnbar</h3>
|
||||
<b>_fillconnbar</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl._fillmbar" ID="RevPiPyControl._fillmbar"></a>
|
||||
<p>
|
||||
Generiert Menüeinträge für Verbindungen.
|
||||
</p><a NAME="RevPiPyControl._fillmbar" ID="RevPiPyControl._fillmbar"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._fillmbar</h3>
|
||||
<b>_fillmbar</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl._opt_conn" ID="RevPiPyControl._opt_conn"></a>
|
||||
<p>
|
||||
Generiert Menüeinträge.
|
||||
</p><a NAME="RevPiPyControl._opt_conn" ID="RevPiPyControl._opt_conn"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl._opt_conn</h3>
|
||||
<b>_opt_conn</b>(<i>text</i>)
|
||||
<a NAME="RevPiPyControl.plclist" ID="RevPiPyControl.plclist"></a>
|
||||
<a NAME="RevPiPyControl.infowindow" ID="RevPiPyControl.infowindow"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.infowindow</h3>
|
||||
<b>infowindow</b>(<i></i>)
|
||||
<p>
|
||||
Öffnet das Fenster für die Verbindungen.
|
||||
</p><a NAME="RevPiPyControl.plcdebug" ID="RevPiPyControl.plcdebug"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcdebug</h3>
|
||||
<b>plcdebug</b>(<i></i>)
|
||||
<p>
|
||||
Baut den Debugframe und packt ihn.
|
||||
</p><a NAME="RevPiPyControl.plclist" ID="RevPiPyControl.plclist"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plclist</h3>
|
||||
<b>plclist</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.plclogs" ID="RevPiPyControl.plclogs"></a>
|
||||
<p>
|
||||
Öffnet das Fenster für die Verbindungen.
|
||||
</p><a NAME="RevPiPyControl.plclogs" ID="RevPiPyControl.plclogs"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plclogs</h3>
|
||||
<b>plclogs</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.plcmonitor" ID="RevPiPyControl.plcmonitor"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcmonitor</h3>
|
||||
<b>plcmonitor</b>(<i></i>)
|
||||
<p>
|
||||
Startet das Monitorfenster.
|
||||
Öffnet das Fenster für Logdateien.
|
||||
</p><a NAME="RevPiPyControl.plcoptions" ID="RevPiPyControl.plcoptions"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcoptions</h3>
|
||||
@@ -160,50 +205,49 @@ Startet das Optionsfenster.
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcprogram</h3>
|
||||
<b>plcprogram</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.plcrestart" ID="RevPiPyControl.plcrestart"></a>
|
||||
<p>
|
||||
Startet das Programmfenster.
|
||||
</p><a NAME="RevPiPyControl.plcrestart" ID="RevPiPyControl.plcrestart"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcrestart</h3>
|
||||
<b>plcrestart</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.plcstart" ID="RevPiPyControl.plcstart"></a>
|
||||
<p>
|
||||
Startet das PLC Programm neu.
|
||||
</p><a NAME="RevPiPyControl.plcstart" ID="RevPiPyControl.plcstart"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcstart</h3>
|
||||
<b>plcstart</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.plcstop" ID="RevPiPyControl.plcstop"></a>
|
||||
<p>
|
||||
Startet das PLC Programm.
|
||||
</p><a NAME="RevPiPyControl.plcstop" ID="RevPiPyControl.plcstop"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.plcstop</h3>
|
||||
<b>plcstop</b>(<i></i>)
|
||||
<a NAME="RevPiPyControl.servererror" ID="RevPiPyControl.servererror"></a>
|
||||
<p>
|
||||
Beendet das PLC Programm.
|
||||
</p><a NAME="RevPiPyControl.serverdisconnect" ID="RevPiPyControl.serverdisconnect"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.serverdisconnect</h3>
|
||||
<b>serverdisconnect</b>(<i></i>)
|
||||
<p>
|
||||
Trennt eine bestehende Verbindung.
|
||||
</p><a NAME="RevPiPyControl.servererror" ID="RevPiPyControl.servererror"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.servererror</h3>
|
||||
<b>servererror</b>(<i></i>)
|
||||
<p>
|
||||
Setzt alles auf NULL.
|
||||
Setzt alles zurück für neue Verbindungen.
|
||||
</p><a NAME="RevPiPyControl.tmr_plcrunning" ID="RevPiPyControl.tmr_plcrunning"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.tmr_plcrunning</h3>
|
||||
<b>tmr_plcrunning</b>(<i></i>)
|
||||
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr /><hr />
|
||||
<a NAME="addroot" ID="addroot"></a>
|
||||
<h2 style="background-color:#FFFFFF;color:#0000FF">addroot</h2>
|
||||
<b>addroot</b>(<i>filename</i>)
|
||||
<a NAME="RevPiPyControl.visitwebsite" ID="RevPiPyControl.visitwebsite"></a>
|
||||
<h3 style="background-color:#FFFFFF;color:#FF0000">
|
||||
RevPiPyControl.visitwebsite</h3>
|
||||
<b>visitwebsite</b>(<i></i>)
|
||||
<p>
|
||||
Hängt root-dir der Anwendung vor Dateinamen.
|
||||
</p><p>
|
||||
Je nach Ausführungsart der Anwendung muss das root-dir über
|
||||
andere Arten abgerufen werden.
|
||||
</p><dl>
|
||||
<dt><i>filename:</i></dt>
|
||||
<dd>
|
||||
Datei oder Ordnername
|
||||
</dd>
|
||||
</dl><dl>
|
||||
<dt>Returns:</dt>
|
||||
<dd>
|
||||
root dir
|
||||
</dd>
|
||||
</dl>
|
||||
Öffnet auf dem System einen Webbrowser zur Projektseite.
|
||||
</p>
|
||||
<div align="right"><a style="color:#0000FF" href="#top">Up</a></div>
|
||||
<hr />
|
||||
</body></html>
|
||||
@@ -1,35 +1,54 @@
|
||||
mytools.addroot?4(filename)
|
||||
mytools.gettrans?4(proglang=None)
|
||||
revpicheckclient.RevPiCheckClient.__chval?6(device, io, event=None)
|
||||
revpicheckclient.RevPiCheckClient.__hidewin?6(win, event=None)
|
||||
revpicheckclient.RevPiCheckClient.__saveoldvalue?6(event, tkvar)
|
||||
revpicheckclient.RevPiCheckClient.__showwin?6(win)
|
||||
revpicheckclient.RevPiCheckClient.__spinboxkey?6(device, io, event=None)
|
||||
revpicheckclient.RevPiCheckClient._createiogroup?5(device, frame, iotype)
|
||||
revpicheckclient.RevPiCheckClient._createwidgets?5()
|
||||
revpicheckclient.RevPiCheckClient._readvalues?5()
|
||||
revpicheckclient.RevPiCheckClient.chval?4(device, io)
|
||||
revpicheckclient.RevPiCheckClient.cli?7
|
||||
revpicheckclient.RevPiCheckClient.onfrmconf?4(canvas)
|
||||
revpicheckclient.RevPiCheckClient._onfrmconf?5(canvas)
|
||||
revpicheckclient.RevPiCheckClient._warnwrite?5()
|
||||
revpicheckclient.RevPiCheckClient._workvalues?5(io_dicts=None, writeout=False)
|
||||
revpicheckclient.RevPiCheckClient.hideallwindows?4()
|
||||
revpicheckclient.RevPiCheckClient.readvalues?4()
|
||||
revpicheckclient.RevPiCheckClient.tk?7
|
||||
revpicheckclient.RevPiCheckClient.refreshvalues?4()
|
||||
revpicheckclient.RevPiCheckClient.toggleauto?4()
|
||||
revpicheckclient.RevPiCheckClient.togglewrite?4()
|
||||
revpicheckclient.RevPiCheckClient.validatereturn?4(returnlist)
|
||||
revpicheckclient.RevPiCheckClient.writevalues?4()
|
||||
revpicheckclient.RevPiCheckClient?1(master, xmlcli, xmlmode=0)
|
||||
revpicheckclient._?8
|
||||
revpiinfo.RevPiInfo._closewin?5(event=None)
|
||||
revpiinfo.RevPiInfo._createwidgets?5()
|
||||
revpiinfo.RevPiInfo.app?7
|
||||
revpiinfo.RevPiInfo.root?7
|
||||
revpiinfo.RevPiInfo?1(master)
|
||||
revpiinfo._?8
|
||||
revpilogfile.RevPiLogfile._closewin?5(event)
|
||||
revpilogfile.RevPiLogfile._createwidgets?5()
|
||||
revpilogfile.RevPiLogfile._load_log?5(textwidget, xmlcall, startposition, full)
|
||||
revpilogfile.RevPiLogfile.btn_clearapp?4()
|
||||
revpilogfile.RevPiLogfile.btn_clearplc?4()
|
||||
revpilogfile.RevPiLogfile.get_applines?4()
|
||||
revpilogfile.RevPiLogfile.get_applog?4()
|
||||
revpilogfile.RevPiLogfile.get_plclines?4()
|
||||
revpilogfile.RevPiLogfile.get_plclog?4()
|
||||
revpilogfile.RevPiLogfile.get_applog?4(full=False)
|
||||
revpilogfile.RevPiLogfile.get_plclog?4(full=False)
|
||||
revpilogfile.RevPiLogfile?1(master, xmlcli)
|
||||
revpilogfile._?8
|
||||
revpioption.RevPiOption._changesdone?5()
|
||||
revpioption.RevPiOption._checkclose?5(event=None)
|
||||
revpioption.RevPiOption._createwidgets?5()
|
||||
revpioption.RevPiOption._loadappdata?5()
|
||||
revpioption.RevPiOption._setappdata?5()
|
||||
revpioption.RevPiOption.askxmlon?4()
|
||||
revpioption.RevPiOption.xmlmods?4()
|
||||
revpioption.RevPiOption?1(master, xmlcli, xmlmode)
|
||||
revpioption._?8
|
||||
revpiplclist.RevPiPlcList._checkclose?5(event=None)
|
||||
revpiplclist.RevPiPlcList._createwidgets?5()
|
||||
revpiplclist.RevPiPlcList._loadappdata?5()
|
||||
revpiplclist.RevPiPlcList._saveappdata?5()
|
||||
revpiplclist.RevPiPlcList.build_listconn?4()
|
||||
revpiplclist.RevPiPlcList.evt_btnadd?4()
|
||||
revpiplclist.RevPiPlcList.evt_btnclose?4()
|
||||
revpiplclist.RevPiPlcList.evt_btnnew?4()
|
||||
revpiplclist.RevPiPlcList.evt_btnremove?4()
|
||||
revpiplclist.RevPiPlcList.evt_btnsave?4()
|
||||
@@ -38,8 +57,10 @@ revpiplclist.RevPiPlcList.evt_listconn?4(evt=None)
|
||||
revpiplclist.RevPiPlcList.myapp?7
|
||||
revpiplclist.RevPiPlcList.root?7
|
||||
revpiplclist.RevPiPlcList?1(master)
|
||||
revpiplclist._?8
|
||||
revpiplclist.get_connections?4()
|
||||
revpiplclist.savefile?7
|
||||
revpiprogram.RevPiProgram._checkclose?5(event=None)
|
||||
revpiprogram.RevPiProgram._createwidgets?5()
|
||||
revpiprogram.RevPiProgram._evt_optdown?5(text="")
|
||||
revpiprogram.RevPiProgram._evt_optup?5(text="")
|
||||
@@ -49,31 +70,34 @@ revpiprogram.RevPiProgram.check_replacedir?4(rootdir)
|
||||
revpiprogram.RevPiProgram.create_filelist?4(rootdir)
|
||||
revpiprogram.RevPiProgram.getpictoryrsc?4()
|
||||
revpiprogram.RevPiProgram.getprocimg?4()
|
||||
revpiprogram.RevPiProgram.myapp?7
|
||||
revpiprogram.RevPiProgram.picontrolreset?4()
|
||||
revpiprogram.RevPiProgram.plcdownload?4()
|
||||
revpiprogram.RevPiProgram.plcupload?4()
|
||||
revpiprogram.RevPiProgram.root?7
|
||||
revpiprogram.RevPiProgram.setpictoryrsc?4(filename=None)
|
||||
revpiprogram.RevPiProgram?1(master, xmlcli, xmlmode, revpi)
|
||||
revpiprogram._?8
|
||||
revpiprogram.savefile?7
|
||||
revpipycontrol.RevPiPyControl._btnstate?5()
|
||||
revpipycontrol.RevPiPyControl._closeall?5()
|
||||
revpipycontrol.RevPiPyControl._closeapp?5(event=None)
|
||||
revpipycontrol.RevPiPyControl._createwidgets?5()
|
||||
revpipycontrol.RevPiPyControl._fillconnbar?5()
|
||||
revpipycontrol.RevPiPyControl._fillmbar?5()
|
||||
revpipycontrol.RevPiPyControl._opt_conn?5(text)
|
||||
revpipycontrol.RevPiPyControl.infowindow?4()
|
||||
revpipycontrol.RevPiPyControl.myapp?7
|
||||
revpipycontrol.RevPiPyControl.plcdebug?4()
|
||||
revpipycontrol.RevPiPyControl.plclist?4()
|
||||
revpipycontrol.RevPiPyControl.plclogs?4()
|
||||
revpipycontrol.RevPiPyControl.plcmonitor?4()
|
||||
revpipycontrol.RevPiPyControl.plcoptions?4()
|
||||
revpipycontrol.RevPiPyControl.plcprogram?4()
|
||||
revpipycontrol.RevPiPyControl.plcrestart?4()
|
||||
revpipycontrol.RevPiPyControl.plcstart?4()
|
||||
revpipycontrol.RevPiPyControl.plcstop?4()
|
||||
revpipycontrol.RevPiPyControl.root?7
|
||||
revpipycontrol.RevPiPyControl.serverdisconnect?4()
|
||||
revpipycontrol.RevPiPyControl.servererror?4()
|
||||
revpipycontrol.RevPiPyControl.tmr_plcrunning?4()
|
||||
revpipycontrol.RevPiPyControl.visitwebsite?4()
|
||||
revpipycontrol.RevPiPyControl?1(master=None)
|
||||
revpipycontrol.addroot?4(filename)
|
||||
revpipycontrol._?8
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
RevPiCheckClient tkinter.Frame
|
||||
RevPiInfo tkinter.Frame
|
||||
RevPiLogfile tkinter.Frame
|
||||
RevPiOption tkinter.Frame
|
||||
RevPiPlcList tkinter.Frame
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE Project SYSTEM "Project-5.1.dtd">
|
||||
<!-- eric project file for project revpipycontrol -->
|
||||
<!-- Saved: 2017-06-29, 17:51:42 -->
|
||||
<!-- Saved: 2017-06-30, 13:49:59 -->
|
||||
<!-- Copyright (C) 2017 Sven Sager, akira@narux.de -->
|
||||
<Project version="5.1">
|
||||
<Language>en_US</Language>
|
||||
@@ -22,6 +22,7 @@
|
||||
<Source>revpipycontrol/revpioption.py</Source>
|
||||
<Source>revpipycontrol/revpiprogram.py</Source>
|
||||
<Source>revpipycontrol/mytools.py</Source>
|
||||
<Source>revpipycontrol/revpiinfo.py</Source>
|
||||
</Sources>
|
||||
<Forms/>
|
||||
<Translations/>
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
msgid ""
|
||||
msgstr ""
|
||||
"Project-Id-Version: RevPiPyControl 0.4.0\n"
|
||||
"POT-Creation-Date: 2017-06-29 20:10+0200\n"
|
||||
"PO-Revision-Date: 2017-06-29 20:10+0200\n"
|
||||
"POT-Creation-Date: 2017-06-30 13:50+0200\n"
|
||||
"PO-Revision-Date: 2017-06-30 13:50+0200\n"
|
||||
"Last-Translator: \n"
|
||||
"Language-Team: \n"
|
||||
"Language: de\n"
|
||||
@@ -15,34 +15,72 @@ msgstr ""
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
"X-Poedit-SearchPath-0: .\n"
|
||||
|
||||
#: revpicheckclient.py:143
|
||||
#: revpicheckclient.py:103 revpicheckclient.py:395 revpioption.py:288
|
||||
#: revpiplclist.py:198 revpiprogram.py:306 revpiprogram.py:337
|
||||
#: revpiprogram.py:400 revpiprogram.py:433 revpiprogram.py:515
|
||||
#: revpiprogram.py:587 revpiprogram.py:618 revpiprogram.py:631
|
||||
#: revpiprogram.py:686 revpiprogram.py:706 revpiprogram.py:714
|
||||
#: revpipycontrol.py:342
|
||||
msgid "Error"
|
||||
msgstr "Fehler"
|
||||
|
||||
#: revpicheckclient.py:104
|
||||
msgid ""
|
||||
"Given value for Output '{}' is not valid! \n"
|
||||
"Reset to '{}'"
|
||||
msgstr ""
|
||||
"Angegebener Wert bei Output '{}' ist nicht gültig! \n"
|
||||
"Setze auf '{}' zurück"
|
||||
|
||||
#: revpicheckclient.py:202
|
||||
msgid "Devices of RevPi"
|
||||
msgstr "Devices vom RevPi"
|
||||
|
||||
#: revpicheckclient.py:175
|
||||
#: revpicheckclient.py:234
|
||||
msgid "Control"
|
||||
msgstr "Kontrolle"
|
||||
|
||||
#: revpicheckclient.py:179
|
||||
#: revpicheckclient.py:238
|
||||
msgid "Read all IOs"
|
||||
msgstr "IOs aktualisieren"
|
||||
|
||||
#: revpicheckclient.py:184
|
||||
#: revpicheckclient.py:243
|
||||
msgid "Read just Inputs"
|
||||
msgstr "Inputs lesen"
|
||||
|
||||
#: revpicheckclient.py:189
|
||||
#: revpicheckclient.py:248
|
||||
msgid "Write Outputs"
|
||||
msgstr "Outputs schreiben"
|
||||
|
||||
#: revpicheckclient.py:195
|
||||
#: revpicheckclient.py:254
|
||||
msgid "Autorefresh values"
|
||||
msgstr "Aktualisiere automatisch"
|
||||
|
||||
#: revpicheckclient.py:201
|
||||
#: revpicheckclient.py:262
|
||||
msgid "Write values to RevPi"
|
||||
msgstr "Schreibe Werte auf RevPi"
|
||||
|
||||
#: revpicheckclient.py:276 revpiprogram.py:407 revpipycontrol.py:228
|
||||
#: revpipycontrol.py:267 revpipycontrol.py:285 revpipycontrol.py:303
|
||||
msgid "Warning"
|
||||
msgstr "Warnung"
|
||||
|
||||
#: revpicheckclient.py:277
|
||||
msgid ""
|
||||
"You want to set outputs on the RevPi! Note that these are set "
|
||||
"IMMEDIATELY!!! \n"
|
||||
"If another control program is running on the RevPi, it could interfere and "
|
||||
"reset the outputs."
|
||||
msgstr ""
|
||||
"Sie wollen Outputs auf dem RevPi setzen! Beachten Sie, dass diese SOFORT "
|
||||
"gesetzt werden!!! \n"
|
||||
"Wenn auf dem RevPi ein anderes Programm zur Steuerung läuft, könnte dies "
|
||||
"gestört werden und die Ausgänge wieder zurücksetzen."
|
||||
|
||||
#: revpicheckclient.py:392
|
||||
msgid "Error set value of device '{}' Output '{}': {} \n"
|
||||
msgstr "Fehler beim Setzen auf Device '{}' bei Output '{}': {}\n"
|
||||
|
||||
#: revpilogfile.py:37
|
||||
msgid "RevPi Python PLC Logs"
|
||||
msgstr "RevPi Python PLC Logdaten"
|
||||
@@ -184,14 +222,6 @@ msgstr "Information"
|
||||
msgid "Settings saved"
|
||||
msgstr "Einstellungen gespeichert"
|
||||
|
||||
#: revpioption.py:288 revpiplclist.py:198 revpiprogram.py:306
|
||||
#: revpiprogram.py:337 revpiprogram.py:400 revpiprogram.py:433
|
||||
#: revpiprogram.py:515 revpiprogram.py:587 revpiprogram.py:618
|
||||
#: revpiprogram.py:631 revpiprogram.py:686 revpiprogram.py:706
|
||||
#: revpiprogram.py:714 revpipycontrol.py:325
|
||||
msgid "Error"
|
||||
msgstr "Fehler"
|
||||
|
||||
#: revpioption.py:289
|
||||
msgid "The settings could not be saved. This can happen if values are wrong!"
|
||||
msgstr ""
|
||||
@@ -345,7 +375,7 @@ msgstr "piControlReset ausführen"
|
||||
msgid "execute"
|
||||
msgstr "ausführen"
|
||||
|
||||
#: revpiprogram.py:216 revpipycontrol.py:95
|
||||
#: revpiprogram.py:216 revpipycontrol.py:107
|
||||
msgid "Exit"
|
||||
msgstr "Beenden"
|
||||
|
||||
@@ -412,11 +442,6 @@ msgstr ""
|
||||
"Die piCtory Konfiguration konnte auf dem Revolution Pi nicht geschrieben "
|
||||
"werden."
|
||||
|
||||
#: revpiprogram.py:407 revpipycontrol.py:211 revpipycontrol.py:250
|
||||
#: revpipycontrol.py:268 revpipycontrol.py:286
|
||||
msgid "Warning"
|
||||
msgstr "Warnung"
|
||||
|
||||
#: revpiprogram.py:408
|
||||
msgid ""
|
||||
"The piCtroy configuration has been saved successfully. \n"
|
||||
@@ -486,67 +511,67 @@ msgstr "Der Revoluton Pi konnte Teile der Übertragung nicht verarbeiten."
|
||||
msgid "Errors occurred during transmission"
|
||||
msgstr "Bei der Übertragung traten Fehler auf"
|
||||
|
||||
#: revpipycontrol.py:93
|
||||
#: revpipycontrol.py:105
|
||||
msgid "Connections..."
|
||||
msgstr "Verbindungen..."
|
||||
|
||||
#: revpipycontrol.py:96
|
||||
#: revpipycontrol.py:108
|
||||
msgid "Main"
|
||||
msgstr "Datei"
|
||||
|
||||
#: revpipycontrol.py:104
|
||||
#: revpipycontrol.py:116
|
||||
msgid "Visit website..."
|
||||
msgstr "Webseite besuchen..."
|
||||
|
||||
#: revpipycontrol.py:106
|
||||
#: revpipycontrol.py:118
|
||||
msgid "Info..."
|
||||
msgstr "Info..."
|
||||
|
||||
#: revpipycontrol.py:108
|
||||
#: revpipycontrol.py:119
|
||||
msgid "Help"
|
||||
msgstr "Hilfe"
|
||||
|
||||
#: revpipycontrol.py:116
|
||||
#: revpipycontrol.py:127
|
||||
msgid "PLC start"
|
||||
msgstr "PLC Start"
|
||||
|
||||
#: revpipycontrol.py:121
|
||||
#: revpipycontrol.py:132
|
||||
msgid "PLC stop"
|
||||
msgstr "PLC Stopp"
|
||||
|
||||
#: revpipycontrol.py:126
|
||||
#: revpipycontrol.py:137
|
||||
msgid "PLC restart"
|
||||
msgstr "PLC Neustart"
|
||||
|
||||
#: revpipycontrol.py:131
|
||||
#: revpipycontrol.py:142
|
||||
msgid "PLC logs"
|
||||
msgstr "PLC Logs"
|
||||
|
||||
#: revpipycontrol.py:142
|
||||
#: revpipycontrol.py:153
|
||||
msgid "PLC watch mode"
|
||||
msgstr "PLC watch Modus"
|
||||
|
||||
#: revpipycontrol.py:159
|
||||
#: revpipycontrol.py:170
|
||||
msgid "PLC log..."
|
||||
msgstr "PLC Log..."
|
||||
|
||||
#: revpipycontrol.py:161
|
||||
#: revpipycontrol.py:172
|
||||
msgid "PLC options..."
|
||||
msgstr "PLC Optionen..."
|
||||
|
||||
#: revpipycontrol.py:163
|
||||
#: revpipycontrol.py:174
|
||||
msgid "PLC program..."
|
||||
msgstr "PLC Programm..."
|
||||
|
||||
#: revpipycontrol.py:167
|
||||
#: revpipycontrol.py:178
|
||||
msgid "Disconnect"
|
||||
msgstr "Trennen"
|
||||
|
||||
#: revpipycontrol.py:172
|
||||
#: revpipycontrol.py:183
|
||||
msgid "Connect"
|
||||
msgstr "Verbinden"
|
||||
|
||||
#: revpipycontrol.py:212
|
||||
#: revpipycontrol.py:229
|
||||
msgid ""
|
||||
"The watch mode ist not supported in version {} of RevPiPyLoad on your RevPi! "
|
||||
"You need at least version 0.4.0."
|
||||
@@ -554,7 +579,7 @@ msgstr ""
|
||||
"Der Watch-Modus wird von der RevPiPyLoad Version {} auf dem RevPi nicht "
|
||||
"unterstützt! Sie benötigen mindestens Version 0.4.0."
|
||||
|
||||
#: revpipycontrol.py:251
|
||||
#: revpipycontrol.py:268
|
||||
msgid ""
|
||||
"This version of Logviewer ist not supported in version {} of RevPiPyLoad on "
|
||||
"your RevPi! You need at least version 0.4.1."
|
||||
@@ -562,7 +587,7 @@ msgstr ""
|
||||
"Diese Version vom Logbetrachter wird in der RevPiPyLoad Version {} auf Ihrem "
|
||||
"RevPi nicht unterstützt! Sie benötigen mindestens Version 0.4.1."
|
||||
|
||||
#: revpipycontrol.py:269 revpipycontrol.py:287
|
||||
#: revpipycontrol.py:286 revpipycontrol.py:304
|
||||
msgid ""
|
||||
"XML-RPC access mode in the RevPiPyLoad configuration is to small to access "
|
||||
"this dialog"
|
||||
@@ -570,6 +595,10 @@ msgstr ""
|
||||
"Der XML-RPC Modus ist beim RevPiPyLoad nicht hoch genug eingestellt, um "
|
||||
"diesen Dialog zu verwenden!"
|
||||
|
||||
#: revpipycontrol.py:326
|
||||
#: revpipycontrol.py:343
|
||||
msgid "Can not reach server!"
|
||||
msgstr "Server ist nicht erreichbar!"
|
||||
|
||||
#~ msgid "Given value for Output '{}' is not valid! Reset to '{}'"
|
||||
#~ msgstr ""
|
||||
#~ "Angegebener Wert bei Output '{}' ist nicht gültig! Setze auf '{}' zurück"
|
||||
|
||||
@@ -9,8 +9,9 @@
|
||||
|
||||
import pickle
|
||||
import tkinter
|
||||
from threading import Lock
|
||||
import tkinter.messagebox as tkmsg
|
||||
from mytools import gettrans
|
||||
from threading import Lock
|
||||
from xmlrpc.client import ServerProxy, MultiCall
|
||||
|
||||
# Übersetzung laden
|
||||
@@ -27,12 +28,15 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
self.xmlmode = xmlmode
|
||||
self.cli = xmlcli
|
||||
self.cli.psstart()
|
||||
self.lst_devices = self.cli.ps_devices()
|
||||
self.dict_devices = {v[0]: v[1] for v in self.cli.ps_devices()}
|
||||
self.dict_inps = pickle.loads(self.cli.ps_inps().data)
|
||||
self.dict_outs = pickle.loads(self.cli.ps_outs().data)
|
||||
|
||||
self.lk = Lock()
|
||||
self.lst_wins = []
|
||||
self.dict_wins = {}
|
||||
self.__checkwrite = True
|
||||
self.__lockedvar = None
|
||||
self.__oldvalue = None
|
||||
|
||||
self.autorw = tkinter.BooleanVar()
|
||||
self.dowrite = tkinter.BooleanVar()
|
||||
@@ -43,27 +47,76 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
# Aktuelle Werte einlesen
|
||||
self.refreshvalues()
|
||||
|
||||
def __chval(self, device, io):
|
||||
if self.dowrite.get():
|
||||
def __chval(self, device, io, event=None):
|
||||
u"""Schreibt neuen Output Wert auf den RevPi."""
|
||||
if self.dowrite.get() and self._warnwrite():
|
||||
with self.lk:
|
||||
self.validatereturn(
|
||||
self.cli.ps_setvalue(device, io[0], io[5].get())
|
||||
)
|
||||
|
||||
# Alles neu einlesen wenn nicht AutoRW aktiv ist
|
||||
if not self.autorw.get():
|
||||
self.refreshvalues()
|
||||
|
||||
self.__lockedvar = None
|
||||
|
||||
def __hidewin(self, win, event=None):
|
||||
u"""Verbergt übergebenes Fenster.
|
||||
@param win: Fenster zum verbergen
|
||||
@param event: Tkinter Event"""
|
||||
win.withdraw()
|
||||
|
||||
def __saveoldvalue(self, event, tkvar):
|
||||
u"""Speichert bei Keypress aktuellen Wert für wiederherstellung."""
|
||||
if self.__lockedvar is None:
|
||||
self.__lockedvar = tkvar
|
||||
try:
|
||||
self.__oldvalue = tkvar.get()
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
def __showwin(self, win):
|
||||
u"""Zeigt oder verbergt übergebenes Fenster.
|
||||
@param win: Fenster zum anzeigen/verbergen"""
|
||||
if win.winfo_viewable():
|
||||
win.withdraw()
|
||||
else:
|
||||
win.deiconify()
|
||||
|
||||
def _createiogroup(self, device, frame, iotype):
|
||||
"""Erstellt IO-Gruppen."""
|
||||
def __spinboxkey(self, device, io, event=None):
|
||||
u"""Prüft die Eingabe auf plausibilität.
|
||||
@param event: tkinter Event
|
||||
@param io: IO Liste mit tkinter Variable"""
|
||||
# io = [name,bytelen,byteaddr,bmk,bitaddress,(tkinter_var)]
|
||||
try:
|
||||
newvalue = io[5].get()
|
||||
# Wertebereich prüfen
|
||||
if newvalue < 0 or newvalue > 255 * io[1]:
|
||||
raise ValueError("too big")
|
||||
|
||||
self.__chval(device, io)
|
||||
|
||||
except Exception:
|
||||
io[5].set(self.__oldvalue)
|
||||
tkmsg.showerror(
|
||||
_("Error"),
|
||||
_("Given value for Output '{}' is not valid! \nReset to ""'{}'"
|
||||
"").format(self.dict_devices[device], self.__oldvalue),
|
||||
parent=self.dict_wins[device]
|
||||
)
|
||||
|
||||
# Focus zurücksetzen
|
||||
event.widget.focus_set()
|
||||
|
||||
def _createiogroup(self, device, frame, iotype):
|
||||
u"""Erstellt IO-Gruppen.
|
||||
|
||||
@param device: Deviceposition
|
||||
@param frame: tkinter Frame
|
||||
@iotype: 'inp' oder 'out' als str()
|
||||
|
||||
"""
|
||||
# IO-Typen festlegen
|
||||
if iotype == "inp":
|
||||
lst_io = self.dict_inps[device]
|
||||
@@ -120,10 +173,16 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
check.grid(column=1, row=rowcount)
|
||||
else:
|
||||
var = tkinter.IntVar()
|
||||
|
||||
# FIXME: Mehrere Bytes möglich
|
||||
txt = tkinter.Spinbox(s_frame, to=255 * io[1])
|
||||
|
||||
txt.bind(
|
||||
"<Key>",
|
||||
lambda event, tkvar=var: self.__saveoldvalue(event, tkvar)
|
||||
)
|
||||
txt.bind(
|
||||
"<FocusOut>",
|
||||
lambda event, device=device, io=io:
|
||||
self.__spinboxkey(device, io, event)
|
||||
)
|
||||
txt["command"] = \
|
||||
lambda device=device, io=io: self.__chval(device, io)
|
||||
txt["state"] = "disabled" if iotype == "inp" else "normal"
|
||||
@@ -131,7 +190,7 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
txt["textvariable"] = var
|
||||
txt.grid(column=1, row=rowcount)
|
||||
|
||||
# Steuerelementvariable in IO übernehmen
|
||||
# Steuerelementvariable in IO übernehmen (mutabel)
|
||||
io.append(var)
|
||||
|
||||
rowcount += 1
|
||||
@@ -143,31 +202,31 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
devgrp["text"] = _("Devices of RevPi")
|
||||
devgrp.pack(fill="y", side="left")
|
||||
|
||||
for dev in self.lst_devices:
|
||||
for dev in self.dict_devices:
|
||||
win = tkinter.Toplevel(self)
|
||||
win.wm_title(dev[1])
|
||||
win.wm_title(self.dict_devices[dev])
|
||||
win.protocol(
|
||||
"WM_DELETE_WINDOW",
|
||||
lambda win=win: self.__hidewin(win)
|
||||
)
|
||||
win.resizable(False, True)
|
||||
win.withdraw()
|
||||
self.lst_wins.append(win)
|
||||
self.dict_wins[dev] = win
|
||||
|
||||
# Devicegruppe erstellen
|
||||
group = tkinter.LabelFrame(win)
|
||||
group["text"] = dev[1]
|
||||
group["text"] = self.dict_devices[dev]
|
||||
group.pack(side="left", fill="both", expand=True)
|
||||
|
||||
for iotype in ["inp", "out"]:
|
||||
frame = tkinter.Frame(group)
|
||||
frame.pack(side="left", fill="both", expand=True)
|
||||
self._createiogroup(dev[0], frame, iotype)
|
||||
self._createiogroup(dev, frame, iotype)
|
||||
|
||||
# Button erstellen
|
||||
btn = tkinter.Button(devgrp)
|
||||
btn["command"] = lambda win=win: self.__showwin(win)
|
||||
btn["text"] = dev[1]
|
||||
btn["text"] = self.dict_devices[dev]
|
||||
btn.pack(fill="x", padx=10, pady=5)
|
||||
|
||||
# Steuerungsfunktionen
|
||||
@@ -196,17 +255,38 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
check["variable"] = self.autorw
|
||||
check.pack(anchor="w")
|
||||
|
||||
check = tkinter.Checkbutton(cntgrp)
|
||||
check["state"] = "disabled" if self.xmlmode < 3 else "normal"
|
||||
check["text"] = _("Write values to RevPi")
|
||||
check["variable"] = self.dowrite
|
||||
check.pack(anchor="w")
|
||||
self.chk_dowrite = tkinter.Checkbutton(cntgrp)
|
||||
self.chk_dowrite["command"] = self.togglewrite
|
||||
self.chk_dowrite["state"] = "normal" if self.xmlmode >= 3 \
|
||||
and self.autorw.get() else "disabled"
|
||||
self.chk_dowrite["text"] = _("Write values to RevPi")
|
||||
self.chk_dowrite["variable"] = self.dowrite
|
||||
self.chk_dowrite.pack(anchor="w")
|
||||
|
||||
def _onfrmconf(self, canvas):
|
||||
u"""Erstellt Fenster in einem Canvas.
|
||||
@param canvas: Canvas in dem Objekte erstellt werden sollen"""
|
||||
canvas.configure(scrollregion=canvas.bbox("all"))
|
||||
|
||||
def _warnwrite(self):
|
||||
u"""Warnung für Benutzer über Schreibfunktion einmal fragen.
|
||||
@returns: True, wenn Warnung einmal mit OK bestätigt wurde"""
|
||||
if self.__checkwrite:
|
||||
self.__checkwrite = not tkmsg.askokcancel(
|
||||
_("Warning"),
|
||||
_("You want to set outputs on the RevPi! Note that these are "
|
||||
"set IMMEDIATELY!!! \nIf another control program is "
|
||||
"running on the RevPi, it could interfere and reset the "
|
||||
"outputs."),
|
||||
icon=tkmsg.WARNING,
|
||||
parent=self.master
|
||||
)
|
||||
return not self.__checkwrite
|
||||
|
||||
def _workvalues(self, io_dicts=None, writeout=False):
|
||||
"""Alle Werte der Inputs und Outputs abrufen."""
|
||||
u"""Alle Werte der Inputs und Outputs abrufen.
|
||||
@param io_dicts: Arbeit nur für dieses Dict()
|
||||
@param writeout: Änderungen auf RevPi schreiben"""
|
||||
|
||||
# Abfragelisten vorbereiten
|
||||
if io_dicts is None:
|
||||
@@ -220,13 +300,17 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
if writeout:
|
||||
xmlmc = MultiCall(self.cli)
|
||||
|
||||
for dev in self.lst_devices:
|
||||
for dev in self.dict_devices:
|
||||
# io = [name,bytelen,byteaddr,bmk,bitaddress,(tkinter_var)]
|
||||
|
||||
# IO Typ verarbeiten
|
||||
for iotype in io_dicts:
|
||||
# ios verarbeiten
|
||||
for io in iotype[dev[0]]:
|
||||
for io in iotype[dev]:
|
||||
|
||||
# Gesperrte Variable überspringen
|
||||
if io[5] == self.__lockedvar:
|
||||
continue
|
||||
|
||||
# Bytes umwandeln
|
||||
int_byte = int.from_bytes(
|
||||
@@ -236,55 +320,81 @@ class RevPiCheckClient(tkinter.Frame):
|
||||
# Bit-IO
|
||||
new_val = bool(int_byte & 1 << io[4])
|
||||
if writeout and new_val != io[5].get():
|
||||
xmlmc.ps_setvalue(dev[0], io[0], io[5].get())
|
||||
xmlmc.ps_setvalue(dev, io[0], io[5].get())
|
||||
else:
|
||||
io[5].set(new_val)
|
||||
else:
|
||||
# Byte-IO
|
||||
if writeout and int_byte != io[5].get():
|
||||
xmlmc.ps_setvalue(dev[0], io[0], io[5].get())
|
||||
xmlmc.ps_setvalue(dev, io[0], io[5].get())
|
||||
else:
|
||||
io[5].set(int_byte)
|
||||
|
||||
# Werte per Multicall schreiben
|
||||
if writeout:
|
||||
with self.lk:
|
||||
xmlmc()
|
||||
self.validatereturn(xmlmc())
|
||||
|
||||
if self.autorw.get():
|
||||
self.master.after(200, self._workvalues)
|
||||
|
||||
def hideallwindows(self):
|
||||
for win in self.lst_wins:
|
||||
win.withdraw()
|
||||
u"""Versteckt alle Fenster."""
|
||||
for win in self.dict_wins:
|
||||
self.dict_wins[win].withdraw()
|
||||
|
||||
def readvalues(self):
|
||||
u"""Ruft nur Input Werte von RevPi ab und aktualisiert Fenster."""
|
||||
if not self.autorw.get():
|
||||
self._workvalues([self.dict_inps])
|
||||
|
||||
def refreshvalues(self):
|
||||
u"""Ruft alle IO Werte von RevPi ab und aktualisiert Fenster."""
|
||||
if not self.autorw.get():
|
||||
self._workvalues()
|
||||
|
||||
def toggleauto(self):
|
||||
u"""Schaltet zwischen Autorefresh um und aktualisiert Widgets."""
|
||||
stateval = "disabled" if self.autorw.get() else "normal"
|
||||
self.btn_refresh["state"] = stateval
|
||||
self.btn_read["state"] = stateval
|
||||
self.btn_write["state"] = stateval
|
||||
|
||||
self.chk_dowrite["state"] = "normal" if self.xmlmode >= 3 \
|
||||
and self.autorw.get() else "disabled"
|
||||
|
||||
if self.autorw.get():
|
||||
self._workvalues()
|
||||
else:
|
||||
self.dowrite.set(False)
|
||||
|
||||
def togglewrite(self):
|
||||
u"""Schaltet zwischen DoWrite um und aktiviert Schreibfunktion."""
|
||||
if self._warnwrite():
|
||||
self.refreshvalues()
|
||||
else:
|
||||
self.dowrite.set(False)
|
||||
|
||||
def validatereturn(self, returnlist):
|
||||
u"""Überprüft die Rückgaben der setvalue Funktion.
|
||||
@param returnlist: list() der xml Rückgabe"""
|
||||
if type(returnlist[0]) != list:
|
||||
returnlist = [returnlist]
|
||||
|
||||
str_errmsg = ""
|
||||
for lst_result in returnlist:
|
||||
# [device, io, status, msg]
|
||||
|
||||
if not lst_result[2]:
|
||||
# Fehlermeldungen erstellen
|
||||
devicename = self.dict_devices[lst_result[0]]
|
||||
str_errmsg += _(
|
||||
"Error set value of device '{}' Output '{}': {} \n"
|
||||
).format(devicename, lst_result[1], lst_result[3])
|
||||
if str_errmsg != "":
|
||||
tkmsg.showerror(_("Error"), str_errmsg)
|
||||
|
||||
def writevalues(self):
|
||||
if not self.autorw.get():
|
||||
u"""Schreibt geänderte Outputs auf den RevPi."""
|
||||
if self._warnwrite() and not self.autorw.get():
|
||||
self._workvalues([self.dict_outs], True)
|
||||
|
||||
|
||||
# Testdrive
|
||||
if __name__ == "__main__":
|
||||
cli = ServerProxy("http://192.168.50.35:55123")
|
||||
cli.psstart()
|
||||
|
||||
tk = tkinter.Tk()
|
||||
RevPiCheckClient(tk, cli, 3)
|
||||
tk.mainloop()
|
||||
|
||||
@@ -646,7 +646,7 @@ class RevPiProgram(tkinter.Frame):
|
||||
if fname == rscfile:
|
||||
continue
|
||||
|
||||
# TODO: Fehlerabfang bei Dateilesen
|
||||
# FIXME: Fehlerabfang bei Dateilesen
|
||||
with open(fname, "rb") as fh:
|
||||
|
||||
# Dateinamen ermitteln
|
||||
@@ -719,9 +719,3 @@ class RevPiProgram(tkinter.Frame):
|
||||
# Temp-Dir aufräumen
|
||||
if dirtmp is not None:
|
||||
rmtree(dirtmp)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
root = tkinter.Tk()
|
||||
myapp = RevPiProgram(root, None, "test")
|
||||
root.mainloop()
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
#!/usr/bin/python3
|
||||
#
|
||||
# RevPiPyControl
|
||||
# Version: 0.4.1
|
||||
# Version: see global var pycontrolverion
|
||||
#
|
||||
# Webpage: https://revpimodio.org/revpipyplc/
|
||||
# (c) Sven Sager, License: LGPLv3
|
||||
#
|
||||
# -*- coding: utf-8 -*-
|
||||
import revpicheckclient
|
||||
import revpiinfo
|
||||
import revpilogfile
|
||||
import revpioption
|
||||
import revpiplclist
|
||||
@@ -15,6 +16,7 @@ import revpiprogram
|
||||
import socket
|
||||
import tkinter
|
||||
import tkinter.messagebox as tkmsg
|
||||
import webbrowser
|
||||
from functools import partial
|
||||
from mytools import addroot, gettrans
|
||||
from xmlrpc.client import ServerProxy
|
||||
@@ -22,6 +24,8 @@ from xmlrpc.client import ServerProxy
|
||||
# Übersetzung laden
|
||||
_ = gettrans()
|
||||
|
||||
pycontrolversion = "0.4.1"
|
||||
|
||||
|
||||
class RevPiPyControl(tkinter.Frame):
|
||||
|
||||
@@ -29,6 +33,7 @@ class RevPiPyControl(tkinter.Frame):
|
||||
u"""Init RevPiPyControl-Class.
|
||||
@param master: tkinter master"""
|
||||
super().__init__(master)
|
||||
self.master.protocol("WM_DELETE_WINDOW", self._closeapp)
|
||||
self.pack(fill="both", expand=True)
|
||||
|
||||
self.cli = None
|
||||
@@ -74,8 +79,15 @@ class RevPiPyControl(tkinter.Frame):
|
||||
self.tkprogram.destroy()
|
||||
if self.debugframe is not None:
|
||||
self.debugframe.destroy()
|
||||
self.cli.psstop()
|
||||
self.debugframe = None
|
||||
|
||||
def _closeapp(self, event=None):
|
||||
u"""Räumt auf und beendet Programm.
|
||||
@param event: tkinter Event"""
|
||||
self._closeall()
|
||||
self.master.destroy()
|
||||
|
||||
def _createwidgets(self):
|
||||
u"""Erstellt den Fensterinhalt."""
|
||||
# Hauptfenster
|
||||
@@ -104,7 +116,6 @@ class RevPiPyControl(tkinter.Frame):
|
||||
label=_("Visit website..."), command=self.visitwebsite)
|
||||
menu1.add_separator()
|
||||
menu1.add_command(label=_("Info..."), command=self.infowindow)
|
||||
# TODO: Menü einbauen
|
||||
self.mbar.add_cascade(label=_("Help"), menu=menu1)
|
||||
|
||||
self.var_conn = tkinter.StringVar(self)
|
||||
@@ -199,8 +210,14 @@ class RevPiPyControl(tkinter.Frame):
|
||||
self.mbar.entryconfig("PLC", state="normal")
|
||||
|
||||
def infowindow(self):
|
||||
# TODO: Infofenster aufrufen
|
||||
pass
|
||||
u"""Öffnet das Fenster für die Verbindungen."""
|
||||
win = tkinter.Toplevel(self)
|
||||
revpiinfo.RevPiInfo(win)
|
||||
win.focus_set()
|
||||
win.grab_set()
|
||||
self.wait_window(win)
|
||||
self.dict_conn = revpiplclist.get_connections()
|
||||
self._fillconnbar()
|
||||
|
||||
def plcdebug(self):
|
||||
u"""Baut den Debugframe und packt ihn."""
|
||||
@@ -362,8 +379,9 @@ class RevPiPyControl(tkinter.Frame):
|
||||
self.master.after(1000, self.tmr_plcrunning)
|
||||
|
||||
def visitwebsite(self):
|
||||
# TODO: Webseite besuchen
|
||||
pass
|
||||
u"""Öffnet auf dem System einen Webbrowser zur Projektseite."""
|
||||
webbrowser.open("https://revpimodio.org")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
root = tkinter.Tk()
|
||||
|
||||
Reference in New Issue
Block a user