meerk40t 0.9.2000__py2.py3-none-any.whl → 0.9.3001__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- meerk40t/balormk/balor_params.py +1 -43
- meerk40t/balormk/controller.py +1 -41
- meerk40t/balormk/device.py +16 -22
- meerk40t/balormk/driver.py +4 -4
- meerk40t/balormk/gui/balorconfig.py +2 -2
- meerk40t/balormk/gui/balorcontroller.py +13 -5
- meerk40t/balormk/gui/baloroperationproperties.py +0 -46
- meerk40t/balormk/gui/gui.py +17 -17
- meerk40t/camera/gui/camerapanel.py +18 -11
- meerk40t/core/cutcode/rastercut.py +3 -1
- meerk40t/core/cutplan.py +145 -14
- meerk40t/core/elements/clipboard.py +18 -9
- meerk40t/core/elements/element_treeops.py +320 -180
- meerk40t/core/elements/element_types.py +7 -2
- meerk40t/core/elements/elements.py +53 -27
- meerk40t/core/elements/geometry.py +8 -0
- meerk40t/core/elements/offset_clpr.py +129 -4
- meerk40t/core/elements/offset_mk.py +3 -1
- meerk40t/core/elements/shapes.py +28 -25
- meerk40t/core/laserjob.py +7 -0
- meerk40t/core/node/bootstrap.py +4 -0
- meerk40t/core/node/effect_hatch.py +85 -96
- meerk40t/core/node/effect_wobble.py +309 -0
- meerk40t/core/node/elem_image.py +49 -19
- meerk40t/core/node/elem_line.py +60 -0
- meerk40t/core/node/elem_rect.py +5 -3
- meerk40t/core/node/image_processed.py +766 -0
- meerk40t/core/node/image_raster.py +113 -0
- meerk40t/core/node/node.py +120 -1
- meerk40t/core/node/op_cut.py +2 -8
- meerk40t/core/node/op_dots.py +0 -8
- meerk40t/core/node/op_engrave.py +2 -18
- meerk40t/core/node/op_image.py +22 -35
- meerk40t/core/node/op_raster.py +0 -9
- meerk40t/core/planner.py +32 -2
- meerk40t/core/svg_io.py +699 -461
- meerk40t/core/treeop.py +191 -0
- meerk40t/core/undos.py +15 -1
- meerk40t/core/units.py +14 -4
- meerk40t/device/dummydevice.py +3 -2
- meerk40t/device/gui/defaultactions.py +43 -55
- meerk40t/device/gui/formatterpanel.py +58 -49
- meerk40t/device/gui/warningpanel.py +12 -12
- meerk40t/device/mixins.py +13 -0
- meerk40t/dxf/dxf_io.py +9 -5
- meerk40t/extra/ezd.py +28 -26
- meerk40t/extra/imageactions.py +300 -308
- meerk40t/extra/lbrn.py +19 -2
- meerk40t/fill/fills.py +6 -6
- meerk40t/fill/patternfill.py +1061 -1061
- meerk40t/fill/patterns.py +2 -6
- meerk40t/grbl/controller.py +168 -52
- meerk40t/grbl/device.py +23 -18
- meerk40t/grbl/driver.py +39 -0
- meerk40t/grbl/emulator.py +79 -19
- meerk40t/grbl/gcodejob.py +10 -0
- meerk40t/grbl/gui/grblconfiguration.py +2 -2
- meerk40t/grbl/gui/grblcontroller.py +24 -8
- meerk40t/grbl/gui/grblhardwareconfig.py +153 -0
- meerk40t/grbl/gui/gui.py +17 -14
- meerk40t/grbl/mock_connection.py +15 -34
- meerk40t/grbl/plugin.py +0 -4
- meerk40t/grbl/serial_connection.py +2 -1
- meerk40t/gui/about.py +8 -5
- meerk40t/gui/alignment.py +10 -6
- meerk40t/gui/basicops.py +27 -17
- meerk40t/gui/bufferview.py +2 -2
- meerk40t/gui/choicepropertypanel.py +101 -13
- meerk40t/gui/consolepanel.py +12 -9
- meerk40t/gui/devicepanel.py +38 -25
- meerk40t/gui/executejob.py +6 -4
- meerk40t/gui/help_assets/help_assets.py +13 -10
- meerk40t/gui/hersheymanager.py +8 -6
- meerk40t/gui/icons.py +1951 -3065
- meerk40t/gui/imagesplitter.py +14 -7
- meerk40t/gui/keymap.py +3 -3
- meerk40t/gui/laserpanel.py +151 -84
- meerk40t/gui/laserrender.py +61 -70
- meerk40t/gui/lasertoolpanel.py +8 -7
- meerk40t/gui/materialtest.py +3 -3
- meerk40t/gui/mkdebug.py +254 -1
- meerk40t/gui/navigationpanels.py +321 -180
- meerk40t/gui/notes.py +3 -3
- meerk40t/gui/opassignment.py +12 -12
- meerk40t/gui/operation_info.py +13 -13
- meerk40t/gui/plugin.py +5 -0
- meerk40t/gui/position.py +20 -18
- meerk40t/gui/preferences.py +21 -6
- meerk40t/gui/propertypanels/attributes.py +70 -22
- meerk40t/gui/propertypanels/blobproperty.py +2 -2
- meerk40t/gui/propertypanels/consoleproperty.py +2 -2
- meerk40t/gui/propertypanels/groupproperties.py +3 -3
- meerk40t/gui/propertypanels/hatchproperty.py +11 -18
- meerk40t/gui/propertypanels/imageproperty.py +4 -3
- meerk40t/gui/propertypanels/opbranchproperties.py +1 -1
- meerk40t/gui/propertypanels/pathproperty.py +2 -2
- meerk40t/gui/propertypanels/pointproperty.py +2 -2
- meerk40t/gui/propertypanels/propertywindow.py +4 -4
- meerk40t/gui/propertypanels/textproperty.py +3 -3
- meerk40t/gui/propertypanels/wobbleproperty.py +204 -0
- meerk40t/gui/ribbon.py +367 -259
- meerk40t/gui/scene/scene.py +31 -5
- meerk40t/gui/scenewidgets/elementswidget.py +12 -4
- meerk40t/gui/scenewidgets/gridwidget.py +2 -2
- meerk40t/gui/scenewidgets/laserpathwidget.py +7 -2
- meerk40t/gui/scenewidgets/machineoriginwidget.py +6 -2
- meerk40t/gui/scenewidgets/relocatewidget.py +1 -1
- meerk40t/gui/scenewidgets/reticlewidget.py +9 -0
- meerk40t/gui/scenewidgets/selectionwidget.py +12 -7
- meerk40t/gui/simpleui.py +95 -8
- meerk40t/gui/simulation.py +44 -36
- meerk40t/gui/spoolerpanel.py +124 -26
- meerk40t/gui/statusbarwidgets/defaultoperations.py +18 -6
- meerk40t/gui/statusbarwidgets/infowidget.py +2 -2
- meerk40t/gui/statusbarwidgets/opassignwidget.py +12 -12
- meerk40t/gui/statusbarwidgets/shapepropwidget.py +45 -18
- meerk40t/gui/statusbarwidgets/statusbar.py +11 -4
- meerk40t/gui/themes.py +78 -0
- meerk40t/gui/toolwidgets/toolcircle.py +2 -1
- meerk40t/gui/toolwidgets/toolellipse.py +2 -1
- meerk40t/gui/toolwidgets/toolimagecut.py +132 -0
- meerk40t/gui/toolwidgets/toolline.py +144 -0
- meerk40t/gui/toolwidgets/toolnodeedit.py +72 -145
- meerk40t/gui/toolwidgets/toolpoint.py +1 -1
- meerk40t/gui/toolwidgets/toolpolygon.py +8 -55
- meerk40t/gui/toolwidgets/toolrect.py +2 -1
- meerk40t/gui/usbconnect.py +2 -2
- meerk40t/gui/utilitywidgets/cyclocycloidwidget.py +2 -2
- meerk40t/gui/utilitywidgets/harmonograph.py +7 -7
- meerk40t/gui/utilitywidgets/scalewidget.py +1 -1
- meerk40t/gui/wordlisteditor.py +33 -18
- meerk40t/gui/wxmeerk40t.py +166 -66
- meerk40t/gui/wxmmain.py +236 -157
- meerk40t/gui/wxmribbon.py +49 -25
- meerk40t/gui/wxmscene.py +49 -38
- meerk40t/gui/wxmtree.py +216 -85
- meerk40t/gui/wxutils.py +62 -4
- meerk40t/image/imagetools.py +443 -15
- meerk40t/internal_plugins.py +2 -10
- meerk40t/kernel/kernel.py +12 -4
- meerk40t/lihuiyu/controller.py +7 -7
- meerk40t/lihuiyu/device.py +3 -1
- meerk40t/lihuiyu/driver.py +3 -0
- meerk40t/lihuiyu/gui/gui.py +8 -8
- meerk40t/lihuiyu/gui/lhyaccelgui.py +2 -2
- meerk40t/lihuiyu/gui/lhycontrollergui.py +73 -27
- meerk40t/lihuiyu/gui/lhydrivergui.py +2 -2
- meerk40t/lihuiyu/gui/tcpcontroller.py +22 -9
- meerk40t/main.py +6 -1
- meerk40t/moshi/controller.py +5 -5
- meerk40t/moshi/device.py +5 -2
- meerk40t/moshi/driver.py +4 -0
- meerk40t/moshi/gui/gui.py +8 -8
- meerk40t/moshi/gui/moshicontrollergui.py +24 -8
- meerk40t/moshi/gui/moshidrivergui.py +2 -2
- meerk40t/newly/controller.py +2 -0
- meerk40t/newly/device.py +9 -2
- meerk40t/newly/driver.py +4 -0
- meerk40t/newly/gui/gui.py +16 -17
- meerk40t/newly/gui/newlyconfig.py +2 -2
- meerk40t/newly/gui/newlycontroller.py +13 -5
- meerk40t/rotary/gui/gui.py +2 -2
- meerk40t/rotary/gui/rotarysettings.py +2 -2
- meerk40t/ruida/device.py +3 -0
- meerk40t/ruida/driver.py +4 -0
- meerk40t/ruida/gui/gui.py +6 -6
- meerk40t/ruida/gui/ruidaconfig.py +2 -2
- meerk40t/ruida/gui/ruidacontroller.py +13 -5
- meerk40t/svgelements.py +9 -9
- meerk40t/tools/geomstr.py +849 -153
- meerk40t/tools/kerftest.py +8 -4
- meerk40t/tools/livinghinges.py +15 -8
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/METADATA +21 -16
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/RECORD +185 -177
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/entry_points.txt +0 -1
- test/test_core_elements.py +8 -24
- test/test_file_svg.py +88 -0
- test/test_fill.py +9 -9
- test/test_geomstr.py +258 -8
- test/test_kernel.py +4 -0
- test/test_tools_rasterplotter.py +29 -0
- meerk40t/extra/embroider.py +0 -56
- meerk40t/extra/pathoptimize.py +0 -249
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/LICENSE +0 -0
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/WHEEL +0 -0
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/top_level.txt +0 -0
- {meerk40t-0.9.2000.dist-info → meerk40t-0.9.3001.dist-info}/zip-safe +0 -0
meerk40t/lihuiyu/gui/gui.py
CHANGED
@@ -13,10 +13,10 @@ def plugin(service, lifecycle):
|
|
13
13
|
|
14
14
|
if lifecycle == "added":
|
15
15
|
from meerk40t.gui.icons import (
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
16
|
+
icons8_computer_support,
|
17
|
+
icons8_connected,
|
18
|
+
icons8_emergency_stop_button,
|
19
|
+
icons8_pause,
|
20
20
|
)
|
21
21
|
from meerk40t.lihuiyu.gui.lhyaccelgui import LihuiyuAccelerationChart
|
22
22
|
from meerk40t.lihuiyu.gui.lhycontrollergui import LihuiyuControllerGui
|
@@ -51,7 +51,7 @@ def plugin(service, lifecycle):
|
|
51
51
|
"button/control/Controller",
|
52
52
|
{
|
53
53
|
"label": _("Controller"),
|
54
|
-
"icon":
|
54
|
+
"icon": icons8_connected,
|
55
55
|
"tip": _("Opens Controller Window"),
|
56
56
|
"action": controller_click,
|
57
57
|
"alt-action": (
|
@@ -70,7 +70,7 @@ def plugin(service, lifecycle):
|
|
70
70
|
"button/device/Configuration",
|
71
71
|
{
|
72
72
|
"label": _("Config"),
|
73
|
-
"icon":
|
73
|
+
"icon": icons8_computer_support,
|
74
74
|
"tip": _("Opens device-specific configuration window"),
|
75
75
|
"action": lambda v: service("window toggle Configuration\n"),
|
76
76
|
},
|
@@ -79,7 +79,7 @@ def plugin(service, lifecycle):
|
|
79
79
|
"button/control/Pause",
|
80
80
|
{
|
81
81
|
"label": _("Pause"),
|
82
|
-
"icon":
|
82
|
+
"icon": icons8_pause,
|
83
83
|
"tip": _("Pause the laser"),
|
84
84
|
"action": lambda v: service("pause\n"),
|
85
85
|
},
|
@@ -89,7 +89,7 @@ def plugin(service, lifecycle):
|
|
89
89
|
"button/control/Stop",
|
90
90
|
{
|
91
91
|
"label": _("Stop"),
|
92
|
-
"icon":
|
92
|
+
"icon": icons8_emergency_stop_button,
|
93
93
|
"tip": _("Emergency stop the laser"),
|
94
94
|
"action": lambda v: service("estop\n"),
|
95
95
|
},
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import wx
|
2
2
|
|
3
|
-
from meerk40t.gui.icons import
|
3
|
+
from meerk40t.gui.icons import icons8_administrative_tools
|
4
4
|
from meerk40t.gui.mwindow import MWindow
|
5
5
|
from meerk40t.gui.wxutils import ScrolledPanel, StaticBoxSizer, dip_size
|
6
6
|
|
@@ -348,7 +348,7 @@ class LihuiyuAccelerationChart(MWindow):
|
|
348
348
|
)
|
349
349
|
self.add_module_delegate(self.panel)
|
350
350
|
_icon = wx.NullIcon
|
351
|
-
_icon.CopyFromBitmap(
|
351
|
+
_icon.CopyFromBitmap(icons8_administrative_tools.GetBitmap())
|
352
352
|
self.SetIcon(_icon)
|
353
353
|
self.SetTitle(_("Acceleration Chart"))
|
354
354
|
|
@@ -6,12 +6,13 @@ import threading
|
|
6
6
|
import wx
|
7
7
|
|
8
8
|
from meerk40t.gui.icons import (
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
9
|
+
get_default_icon_size,
|
10
|
+
icons8_circled_play,
|
11
|
+
icons8_connected,
|
12
|
+
icons8_disconnected,
|
13
|
+
icons8_emergency_stop_button,
|
14
|
+
icons8_laser_beam_hazard,
|
15
|
+
icons8_pause,
|
15
16
|
)
|
16
17
|
from meerk40t.gui.mwindow import MWindow
|
17
18
|
from meerk40t.gui.wxutils import ScrolledPanel, StaticBoxSizer, dip_size
|
@@ -143,10 +144,14 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
143
144
|
self.text_byte_5.SetMinSize(dip_size(self, 77, 23))
|
144
145
|
self.checkbox_show_usb_log.SetValue(1)
|
145
146
|
self.button_device_connect.SetBitmap(
|
146
|
-
|
147
|
+
icons8_disconnected.GetBitmap(
|
148
|
+
use_theme=False, resize=get_default_icon_size()
|
149
|
+
)
|
147
150
|
)
|
148
151
|
self.button_controller_control.SetBitmap(
|
149
|
-
|
152
|
+
icons8_circled_play.GetBitmap(
|
153
|
+
use_theme=False, resize=get_default_icon_size()
|
154
|
+
)
|
150
155
|
)
|
151
156
|
# end wxGlade
|
152
157
|
|
@@ -260,10 +265,13 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
260
265
|
|
261
266
|
@signal_listener("network_update")
|
262
267
|
def on_network_update(self, origin=None, *args):
|
263
|
-
|
264
|
-
self.
|
265
|
-
|
266
|
-
|
268
|
+
try:
|
269
|
+
if self.context.networked:
|
270
|
+
self.button_device_connect.Enable(False)
|
271
|
+
else:
|
272
|
+
self.button_device_connect.Enable(True)
|
273
|
+
except AttributeError:
|
274
|
+
pass
|
267
275
|
|
268
276
|
def restore(self, *args, **kwargs):
|
269
277
|
self.set_widgets()
|
@@ -347,7 +355,9 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
347
355
|
origin, usb_status = self.context.last_signal("pipe;usb_status")
|
348
356
|
self.button_device_connect.SetLabel(_("Connect failed"))
|
349
357
|
self.button_device_connect.SetBitmap(
|
350
|
-
|
358
|
+
icons8_disconnected.GetBitmap(
|
359
|
+
use_theme=False, resize=get_default_icon_size()
|
360
|
+
)
|
351
361
|
)
|
352
362
|
self.button_device_connect.Enable()
|
353
363
|
elif state == "STATE_FAILED_RETRYING":
|
@@ -355,7 +365,9 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
355
365
|
origin, usb_status = self.context.last_signal("pipe;usb_status")
|
356
366
|
self.button_device_connect.SetLabel(_("Retrying..."))
|
357
367
|
self.button_device_connect.SetBitmap(
|
358
|
-
|
368
|
+
icons8_disconnected.GetBitmap(
|
369
|
+
use_theme=False, resize=get_default_icon_size()
|
370
|
+
)
|
359
371
|
)
|
360
372
|
self.button_device_connect.Enable()
|
361
373
|
elif state == "STATE_FAILED_SUSPENDED":
|
@@ -363,7 +375,9 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
363
375
|
origin, usb_status = self.context.last_signal("pipe;usb_status")
|
364
376
|
self.button_device_connect.SetLabel(_("Suspended Retrying"))
|
365
377
|
self.button_device_connect.SetBitmap(
|
366
|
-
|
378
|
+
icons8_disconnected.GetBitmap(
|
379
|
+
use_theme=False, resize=get_default_icon_size()
|
380
|
+
)
|
367
381
|
)
|
368
382
|
self.button_device_connect.Enable()
|
369
383
|
elif state == "STATE_DRIVER_NO_BACKEND":
|
@@ -371,35 +385,45 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
371
385
|
origin, usb_status = self.context.last_signal("pipe;usb_status")
|
372
386
|
self.button_device_connect.SetLabel(_("No Backend"))
|
373
387
|
self.button_device_connect.SetBitmap(
|
374
|
-
|
388
|
+
icons8_disconnected.GetBitmap(
|
389
|
+
use_theme=False, resize=get_default_icon_size()
|
390
|
+
)
|
375
391
|
)
|
376
392
|
self.button_device_connect.Enable()
|
377
393
|
elif state == "STATE_UNINITIALIZED" or state == "STATE_USB_DISCONNECTED":
|
378
394
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
379
395
|
self.button_device_connect.SetLabel(_("Connect"))
|
380
396
|
self.button_device_connect.SetBitmap(
|
381
|
-
|
397
|
+
icons8_connected.GetBitmap(
|
398
|
+
use_theme=False, resize=get_default_icon_size()
|
399
|
+
)
|
382
400
|
)
|
383
401
|
self.button_device_connect.Enable()
|
384
402
|
elif state == "STATE_USB_SET_DISCONNECTING":
|
385
403
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
386
404
|
self.button_device_connect.SetLabel(_("Disconnecting..."))
|
387
405
|
self.button_device_connect.SetBitmap(
|
388
|
-
|
406
|
+
icons8_disconnected.GetBitmap(
|
407
|
+
use_theme=False, resize=get_default_icon_size()
|
408
|
+
)
|
389
409
|
)
|
390
410
|
self.button_device_connect.Disable()
|
391
411
|
elif state == "STATE_USB_CONNECTED" or state == "STATE_CONNECTED":
|
392
412
|
self.button_device_connect.SetBackgroundColour("#00ff00")
|
393
413
|
self.button_device_connect.SetLabel(_("Disconnect"))
|
394
414
|
self.button_device_connect.SetBitmap(
|
395
|
-
|
415
|
+
icons8_connected.GetBitmap(
|
416
|
+
use_theme=False, resize=get_default_icon_size()
|
417
|
+
)
|
396
418
|
)
|
397
419
|
self.button_device_connect.Enable()
|
398
420
|
elif state == "STATE_CONNECTING":
|
399
421
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
400
422
|
self.button_device_connect.SetLabel(_("Connecting..."))
|
401
423
|
self.button_device_connect.SetBitmap(
|
402
|
-
|
424
|
+
icons8_connected.GetBitmap(
|
425
|
+
use_theme=False, resize=get_default_icon_size()
|
426
|
+
)
|
403
427
|
)
|
404
428
|
self.button_device_connect.Disable()
|
405
429
|
|
@@ -456,12 +480,20 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
456
480
|
button.function = f
|
457
481
|
button.SetBackgroundColour("#009900")
|
458
482
|
button.SetLabel(_("Hold Controller"))
|
459
|
-
button.SetBitmap(
|
483
|
+
button.SetBitmap(
|
484
|
+
icons8_circled_play.GetBitmap(
|
485
|
+
use_theme=False, resize=get_default_icon_size()
|
486
|
+
)
|
487
|
+
)
|
460
488
|
button.Enable(True)
|
461
489
|
elif state == "busy":
|
462
490
|
button.SetBackgroundColour("#00dd00")
|
463
491
|
button.SetLabel(_("LOCKED"))
|
464
|
-
button.SetBitmap(
|
492
|
+
button.SetBitmap(
|
493
|
+
icons8_circled_play.GetBitmap(
|
494
|
+
use_theme=False, resize=get_default_icon_size()
|
495
|
+
)
|
496
|
+
)
|
465
497
|
button.Enable(False)
|
466
498
|
elif state == "wait":
|
467
499
|
|
@@ -471,7 +503,11 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
471
503
|
button.function = f
|
472
504
|
button.SetBackgroundColour("#dddd00")
|
473
505
|
button.SetLabel(_("Force Continue"))
|
474
|
-
button.SetBitmap(
|
506
|
+
button.SetBitmap(
|
507
|
+
icons8_laser_beam_hazard.GetBitmap(
|
508
|
+
use_theme=False, resize=get_default_icon_size()
|
509
|
+
)
|
510
|
+
)
|
475
511
|
button.Enable(True)
|
476
512
|
elif state == "pause":
|
477
513
|
|
@@ -481,7 +517,11 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
481
517
|
button.function = f
|
482
518
|
button.SetBackgroundColour("#00dd00")
|
483
519
|
button.SetLabel(_("Resume Controller"))
|
484
|
-
button.SetBitmap(
|
520
|
+
button.SetBitmap(
|
521
|
+
icons8_circled_play.GetBitmap(
|
522
|
+
use_theme=False, resize=get_default_icon_size()
|
523
|
+
)
|
524
|
+
)
|
485
525
|
button.Enable(True)
|
486
526
|
elif state == "active":
|
487
527
|
|
@@ -491,7 +531,9 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
491
531
|
button.function = f
|
492
532
|
button.SetBackgroundColour("#00ff00")
|
493
533
|
button.SetLabel(_("Pause Controller"))
|
494
|
-
button.SetBitmap(
|
534
|
+
button.SetBitmap(
|
535
|
+
icons8_pause.GetBitmap(use_theme=False, resize=get_default_icon_size())
|
536
|
+
)
|
495
537
|
button.Enable(True)
|
496
538
|
elif state == "terminate":
|
497
539
|
|
@@ -501,7 +543,11 @@ class LihuiyuControllerPanel(ScrolledPanel):
|
|
501
543
|
button.function = f
|
502
544
|
button.SetBackgroundColour("#00ffff")
|
503
545
|
button.SetLabel(_("Manual Reset"))
|
504
|
-
button.SetBitmap(
|
546
|
+
button.SetBitmap(
|
547
|
+
icons8_emergency_stop_button.GetBitmap(
|
548
|
+
use_theme=False, resize=get_default_icon_size()
|
549
|
+
)
|
550
|
+
)
|
505
551
|
button.Enable(True)
|
506
552
|
|
507
553
|
@signal_listener("pipe;failing")
|
@@ -542,7 +588,7 @@ class LihuiyuControllerGui(MWindow):
|
|
542
588
|
self.panel = LihuiyuControllerPanel(self, wx.ID_ANY, context=self.context)
|
543
589
|
self.add_module_delegate(self.panel)
|
544
590
|
_icon = wx.NullIcon
|
545
|
-
_icon.CopyFromBitmap(
|
591
|
+
_icon.CopyFromBitmap(icons8_connected.GetBitmap())
|
546
592
|
self.SetIcon(_icon)
|
547
593
|
self.SetTitle(_("Lihuiyu-Controller"))
|
548
594
|
|
@@ -4,7 +4,7 @@ from meerk40t.device.gui.defaultactions import DefaultActionPanel
|
|
4
4
|
from meerk40t.device.gui.formatterpanel import FormatterPanel
|
5
5
|
from meerk40t.device.gui.warningpanel import WarningPanel
|
6
6
|
from meerk40t.gui.choicepropertypanel import ChoicePropertyPanel
|
7
|
-
from meerk40t.gui.icons import
|
7
|
+
from meerk40t.gui.icons import icons8_administrative_tools
|
8
8
|
from meerk40t.gui.mwindow import MWindow
|
9
9
|
from meerk40t.gui.wxutils import ScrolledPanel, StaticBoxSizer, TextCtrl, dip_size
|
10
10
|
from meerk40t.kernel import signal_listener
|
@@ -371,7 +371,7 @@ class LihuiyuDriverGui(MWindow):
|
|
371
371
|
super().__init__(330, 630, *args, **kwds)
|
372
372
|
self.context = self.context.device
|
373
373
|
_icon = wx.NullIcon
|
374
|
-
_icon.CopyFromBitmap(
|
374
|
+
_icon.CopyFromBitmap(icons8_administrative_tools.GetBitmap())
|
375
375
|
self.SetIcon(_icon)
|
376
376
|
self.SetTitle(_("Lihuiyu-Configuration"))
|
377
377
|
|
@@ -1,6 +1,10 @@
|
|
1
1
|
import wx
|
2
2
|
|
3
|
-
from meerk40t.gui.icons import
|
3
|
+
from meerk40t.gui.icons import (
|
4
|
+
get_default_icon_size,
|
5
|
+
icons8_connected,
|
6
|
+
icons8_disconnected,
|
7
|
+
)
|
4
8
|
from meerk40t.gui.mwindow import MWindow
|
5
9
|
from meerk40t.gui.wxutils import TextCtrl, dip_size
|
6
10
|
from meerk40t.kernel import signal_listener
|
@@ -49,7 +53,7 @@ class TCPController(MWindow):
|
|
49
53
|
# begin wxGlade: Controller.__set_properties
|
50
54
|
self.SetTitle(_("TCP-Controller"))
|
51
55
|
_icon = wx.NullIcon
|
52
|
-
_icon.CopyFromBitmap(
|
56
|
+
_icon.CopyFromBitmap(icons8_connected.GetBitmap())
|
53
57
|
self.SetIcon(_icon)
|
54
58
|
self.button_device_connect.SetBackgroundColour(wx.Colour(102, 255, 102))
|
55
59
|
self.button_device_connect.SetForegroundColour(wx.BLACK)
|
@@ -67,7 +71,9 @@ class TCPController(MWindow):
|
|
67
71
|
_("Force connection/disconnection from the device.")
|
68
72
|
)
|
69
73
|
self.button_device_connect.SetBitmap(
|
70
|
-
|
74
|
+
icons8_disconnected.GetBitmap(
|
75
|
+
use_theme=False, resize=get_default_icon_size()
|
76
|
+
)
|
71
77
|
)
|
72
78
|
self.text_status.SetToolTip(_("Connection status"))
|
73
79
|
self.text_ip_host.SetToolTip(_("IP/Host if the server computer"))
|
@@ -129,10 +135,13 @@ class TCPController(MWindow):
|
|
129
135
|
|
130
136
|
@signal_listener("network_update")
|
131
137
|
def on_network_update(self, origin=None, *args):
|
132
|
-
|
133
|
-
self.
|
134
|
-
|
135
|
-
|
138
|
+
try:
|
139
|
+
if not self.service.networked:
|
140
|
+
self.button_device_connect.Enable(False)
|
141
|
+
else:
|
142
|
+
self.button_device_connect.Enable(True)
|
143
|
+
except AttributeError:
|
144
|
+
pass
|
136
145
|
|
137
146
|
@signal_listener("tcp;status")
|
138
147
|
def on_tcp_status(self, origin, state):
|
@@ -142,14 +151,18 @@ class TCPController(MWindow):
|
|
142
151
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
143
152
|
self.button_device_connect.SetLabel(_("Connect"))
|
144
153
|
self.button_device_connect.SetBitmap(
|
145
|
-
|
154
|
+
icons8_disconnected.GetBitmap(
|
155
|
+
use_theme=False, resize=get_default_icon_size()
|
156
|
+
)
|
146
157
|
)
|
147
158
|
self.button_device_connect.Enable()
|
148
159
|
elif state == "connected":
|
149
160
|
self.button_device_connect.SetBackgroundColour("#00ff00")
|
150
161
|
self.button_device_connect.SetLabel(_("Disconnect"))
|
151
162
|
self.button_device_connect.SetBitmap(
|
152
|
-
|
163
|
+
icons8_connected.GetBitmap(
|
164
|
+
use_theme=False, resize=get_default_icon_size()
|
165
|
+
)
|
153
166
|
)
|
154
167
|
self.button_device_connect.Enable()
|
155
168
|
|
meerk40t/main.py
CHANGED
@@ -10,7 +10,7 @@ import os.path
|
|
10
10
|
import sys
|
11
11
|
|
12
12
|
APPLICATION_NAME = "MeerK40t"
|
13
|
-
APPLICATION_VERSION = "0.9.
|
13
|
+
APPLICATION_VERSION = "0.9.3001"
|
14
14
|
|
15
15
|
if not getattr(sys, "frozen", False):
|
16
16
|
# If .git directory does not exist we are running from a package like pypi
|
@@ -142,7 +142,11 @@ def run():
|
|
142
142
|
###################
|
143
143
|
# END Old Python Code.
|
144
144
|
###################
|
145
|
+
while _exe(args):
|
146
|
+
pass
|
147
|
+
|
145
148
|
|
149
|
+
def _exe(args):
|
146
150
|
from meerk40t.external_plugins import plugin as external_plugins
|
147
151
|
from meerk40t.internal_plugins import plugin as internal_plugins
|
148
152
|
from meerk40t.kernel import Kernel
|
@@ -158,3 +162,4 @@ def run():
|
|
158
162
|
kernel.add_plugin(internal_plugins)
|
159
163
|
kernel.add_plugin(external_plugins)
|
160
164
|
kernel()
|
165
|
+
return hasattr(kernel, "restart") and kernel.restart
|
meerk40t/moshi/controller.py
CHANGED
@@ -341,7 +341,7 @@ class MoshiController:
|
|
341
341
|
self.open()
|
342
342
|
# Stage 0: New Program send.
|
343
343
|
if len(self._buffer) == 0:
|
344
|
-
self.context.
|
344
|
+
self.context.laser_status = "active"
|
345
345
|
self.pipe_channel("New Program")
|
346
346
|
self.wait_until_accepting_packets()
|
347
347
|
MoshiBuilder.prologue(self.connection.write_addr, self.pipe_channel)
|
@@ -351,7 +351,7 @@ class MoshiController:
|
|
351
351
|
continue
|
352
352
|
|
353
353
|
# Stage 1: Send Program.
|
354
|
-
self.context.
|
354
|
+
self.context.laser_status = "active"
|
355
355
|
self.pipe_channel(f"Sending Data... {len(self._buffer)} bytes")
|
356
356
|
self._send_buffer()
|
357
357
|
self.update_status()
|
@@ -363,7 +363,7 @@ class MoshiController:
|
|
363
363
|
self.pipe_channel("Waiting for finish processing.")
|
364
364
|
if len(self._buffer) == 0:
|
365
365
|
self.wait_finished()
|
366
|
-
self.context.
|
366
|
+
self.context.laser_status = "idle"
|
367
367
|
|
368
368
|
except ConnectionRefusedError:
|
369
369
|
if self.is_shutdown:
|
@@ -374,7 +374,7 @@ class MoshiController:
|
|
374
374
|
if self.refuse_counts >= 5:
|
375
375
|
self.context.signal("pipe;state", "STATE_FAILED_RETRYING")
|
376
376
|
self.context.signal("pipe;failing", self.refuse_counts)
|
377
|
-
self.context.
|
377
|
+
self.context.laser_status = "idle"
|
378
378
|
time.sleep(3) # 3-second sleep on failed connection attempt.
|
379
379
|
continue
|
380
380
|
except ConnectionError:
|
@@ -388,7 +388,7 @@ class MoshiController:
|
|
388
388
|
except ConnectionError:
|
389
389
|
pass
|
390
390
|
continue
|
391
|
-
self.context.
|
391
|
+
self.context.laser_status = "idle"
|
392
392
|
self._thread = None
|
393
393
|
self.is_shutdown = False
|
394
394
|
self.update_state("end")
|
meerk40t/moshi/device.py
CHANGED
@@ -11,17 +11,19 @@ from meerk40t.kernel import CommandSyntaxError, Service, signal_listener
|
|
11
11
|
from ..core.laserjob import LaserJob
|
12
12
|
from ..core.spoolers import Spooler
|
13
13
|
from ..core.units import UNITS_PER_MIL, Length
|
14
|
+
from ..device.mixins import Status
|
14
15
|
from .controller import MoshiController
|
15
16
|
from .driver import MoshiDriver
|
16
17
|
|
17
18
|
|
18
|
-
class MoshiDevice(Service):
|
19
|
+
class MoshiDevice(Service, Status):
|
19
20
|
"""
|
20
21
|
MoshiDevice is driver for the Moshiboard boards.
|
21
22
|
"""
|
22
23
|
|
23
24
|
def __init__(self, kernel, path, *args, choices=None, **kwargs):
|
24
25
|
Service.__init__(self, kernel, path)
|
26
|
+
Status.__init__(self)
|
25
27
|
self.name = "MoshiDevice"
|
26
28
|
self.extension = "mos"
|
27
29
|
if choices is not None:
|
@@ -436,4 +438,5 @@ class MoshiDevice(Service):
|
|
436
438
|
1.0 if self.home_right else 0.0, 1.0 if self.home_bottom else 0.0
|
437
439
|
)
|
438
440
|
self.view.realize()
|
439
|
-
self.space.update_bounds(0, 0, self.width, self.height)
|
441
|
+
# self.space.update_bounds(0, 0, self.width, self.height)
|
442
|
+
self.space.update_bounds(0, 0, self.view.width, self.view.height)
|
meerk40t/moshi/driver.py
CHANGED
@@ -498,6 +498,7 @@ class MoshiDriver(Parameters):
|
|
498
498
|
@return:
|
499
499
|
"""
|
500
500
|
self.paused = True
|
501
|
+
self.service.signal("pause")
|
501
502
|
|
502
503
|
def resume(self, *args):
|
503
504
|
"""
|
@@ -509,6 +510,7 @@ class MoshiDriver(Parameters):
|
|
509
510
|
@return:
|
510
511
|
"""
|
511
512
|
self.paused = False
|
513
|
+
self.service.signal("pause")
|
512
514
|
|
513
515
|
def reset(self, *args):
|
514
516
|
"""
|
@@ -524,6 +526,8 @@ class MoshiDriver(Parameters):
|
|
524
526
|
self.pipe_channel("Realtime: Stop")
|
525
527
|
MoshiBuilder.stop(self.out_real)
|
526
528
|
self.pipe_channel("Control Request: Stop")
|
529
|
+
self.paused = False
|
530
|
+
self.service.signal("pause")
|
527
531
|
|
528
532
|
####################
|
529
533
|
# Protected Driver Functions
|
meerk40t/moshi/gui/gui.py
CHANGED
@@ -8,10 +8,10 @@ def plugin(service, lifecycle):
|
|
8
8
|
return "provider/device/moshi"
|
9
9
|
if lifecycle == "added":
|
10
10
|
from meerk40t.gui.icons import (
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
11
|
+
icons8_computer_support,
|
12
|
+
icons8_connected,
|
13
|
+
icons8_emergency_stop_button,
|
14
|
+
icons8_pause,
|
15
15
|
)
|
16
16
|
from meerk40t.moshi.gui.moshicontrollergui import MoshiControllerGui
|
17
17
|
from meerk40t.moshi.gui.moshidrivergui import MoshiDriverGui
|
@@ -28,7 +28,7 @@ def plugin(service, lifecycle):
|
|
28
28
|
"button/control/Controller",
|
29
29
|
{
|
30
30
|
"label": _("Controller"),
|
31
|
-
"icon":
|
31
|
+
"icon": icons8_connected,
|
32
32
|
"tip": _("Opens Controller Window"),
|
33
33
|
"action": lambda e: service("window toggle Controller\n"),
|
34
34
|
},
|
@@ -37,7 +37,7 @@ def plugin(service, lifecycle):
|
|
37
37
|
"button/device/Configuration",
|
38
38
|
{
|
39
39
|
"label": _("Config"),
|
40
|
-
"icon":
|
40
|
+
"icon": icons8_computer_support,
|
41
41
|
"tip": _("Opens device-specific configuration window"),
|
42
42
|
"action": lambda v: service("window toggle Configuration\n"),
|
43
43
|
},
|
@@ -46,7 +46,7 @@ def plugin(service, lifecycle):
|
|
46
46
|
"button/control/Pause",
|
47
47
|
{
|
48
48
|
"label": _("Pause"),
|
49
|
-
"icon":
|
49
|
+
"icon": icons8_emergency_stop_button,
|
50
50
|
"tip": _("Pause the laser"),
|
51
51
|
"action": lambda v: service("pause\n"),
|
52
52
|
},
|
@@ -56,7 +56,7 @@ def plugin(service, lifecycle):
|
|
56
56
|
"button/control/Stop",
|
57
57
|
{
|
58
58
|
"label": _("Stop"),
|
59
|
-
"icon":
|
59
|
+
"icon": icons8_pause,
|
60
60
|
"tip": _("Emergency stop the laser"),
|
61
61
|
"action": lambda v: service("estop\n"),
|
62
62
|
},
|
@@ -2,7 +2,11 @@ import threading
|
|
2
2
|
|
3
3
|
import wx
|
4
4
|
|
5
|
-
from meerk40t.gui.icons import
|
5
|
+
from meerk40t.gui.icons import (
|
6
|
+
get_default_icon_size,
|
7
|
+
icons8_connected,
|
8
|
+
icons8_disconnected,
|
9
|
+
)
|
6
10
|
from meerk40t.gui.mwindow import MWindow
|
7
11
|
from meerk40t.gui.wxutils import StaticBoxSizer, dip_size
|
8
12
|
from meerk40t.kernel import signal_listener
|
@@ -94,7 +98,9 @@ class MoshiControllerPanel(wx.Panel):
|
|
94
98
|
self.button_device_connect.SetBackgroundColour(wx.Colour(102, 255, 102))
|
95
99
|
self.button_device_connect.SetForegroundColour(wx.BLACK)
|
96
100
|
self.button_device_connect.SetBitmap(
|
97
|
-
|
101
|
+
icons8_disconnected.GetBitmap(
|
102
|
+
use_theme=False, resize=get_default_icon_size()
|
103
|
+
)
|
98
104
|
)
|
99
105
|
self.button_device_connect.SetFont(
|
100
106
|
wx.Font(
|
@@ -319,35 +325,45 @@ class MoshiControllerPanel(wx.Panel):
|
|
319
325
|
if usb_status is not None:
|
320
326
|
self.button_device_connect.SetLabel(str(usb_status[0]))
|
321
327
|
self.button_device_connect.SetBitmap(
|
322
|
-
|
328
|
+
icons8_disconnected.GetBitmap(
|
329
|
+
use_theme=False, resize=get_default_icon_size()
|
330
|
+
)
|
323
331
|
)
|
324
332
|
self.button_device_connect.Enable()
|
325
333
|
elif state == "STATE_UNINITIALIZED" or state == "STATE_USB_DISCONNECTED":
|
326
334
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
327
335
|
self.button_device_connect.SetLabel(_("Connect"))
|
328
336
|
self.button_device_connect.SetBitmap(
|
329
|
-
|
337
|
+
icons8_connected.GetBitmap(
|
338
|
+
use_theme=False, resize=get_default_icon_size()
|
339
|
+
)
|
330
340
|
)
|
331
341
|
self.button_device_connect.Enable()
|
332
342
|
elif state == "STATE_USB_SET_DISCONNECTING":
|
333
343
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
334
344
|
self.button_device_connect.SetLabel(_("Disconnecting..."))
|
335
345
|
self.button_device_connect.SetBitmap(
|
336
|
-
|
346
|
+
icons8_disconnected.GetBitmap(
|
347
|
+
use_theme=False, resize=get_default_icon_size()
|
348
|
+
)
|
337
349
|
)
|
338
350
|
self.button_device_connect.Disable()
|
339
351
|
elif state == "STATE_USB_CONNECTED" or state == "STATE_CONNECTED":
|
340
352
|
self.button_device_connect.SetBackgroundColour("#00ff00")
|
341
353
|
self.button_device_connect.SetLabel(_("Disconnect"))
|
342
354
|
self.button_device_connect.SetBitmap(
|
343
|
-
|
355
|
+
icons8_connected.GetBitmap(
|
356
|
+
use_theme=False, resize=get_default_icon_size()
|
357
|
+
)
|
344
358
|
)
|
345
359
|
self.button_device_connect.Enable()
|
346
360
|
elif state == "STATE_CONNECTING":
|
347
361
|
self.button_device_connect.SetBackgroundColour("#ffff00")
|
348
362
|
self.button_device_connect.SetLabel(_("Connecting..."))
|
349
363
|
self.button_device_connect.SetBitmap(
|
350
|
-
|
364
|
+
icons8_connected.GetBitmap(
|
365
|
+
use_theme=False, resize=get_default_icon_size()
|
366
|
+
)
|
351
367
|
)
|
352
368
|
self.button_device_connect.Disable()
|
353
369
|
|
@@ -425,7 +441,7 @@ class MoshiControllerGui(MWindow):
|
|
425
441
|
self.panel = MoshiControllerPanel(self, wx.ID_ANY, context=self.context)
|
426
442
|
self.add_module_delegate(self.panel)
|
427
443
|
_icon = wx.NullIcon
|
428
|
-
_icon.CopyFromBitmap(
|
444
|
+
_icon.CopyFromBitmap(icons8_connected.GetBitmap())
|
429
445
|
self.SetIcon(_icon)
|
430
446
|
self.SetTitle(_("Moshiboard-Controller"))
|
431
447
|
|
@@ -4,7 +4,7 @@ from meerk40t.device.gui.defaultactions import DefaultActionPanel
|
|
4
4
|
from meerk40t.device.gui.formatterpanel import FormatterPanel
|
5
5
|
from meerk40t.device.gui.warningpanel import WarningPanel
|
6
6
|
from meerk40t.gui.choicepropertypanel import ChoicePropertyPanel
|
7
|
-
from meerk40t.gui.icons import
|
7
|
+
from meerk40t.gui.icons import icons8_administrative_tools
|
8
8
|
from meerk40t.gui.mwindow import MWindow
|
9
9
|
|
10
10
|
_ = wx.GetTranslation
|
@@ -15,7 +15,7 @@ class MoshiDriverGui(MWindow):
|
|
15
15
|
super().__init__(330, 630, *args, **kwds)
|
16
16
|
self.context = self.context.device
|
17
17
|
_icon = wx.NullIcon
|
18
|
-
_icon.CopyFromBitmap(
|
18
|
+
_icon.CopyFromBitmap(icons8_administrative_tools.GetBitmap())
|
19
19
|
self.SetIcon(_icon)
|
20
20
|
self.SetTitle(_("Moshiboard-Configuration"))
|
21
21
|
|
meerk40t/newly/controller.py
CHANGED
@@ -352,12 +352,14 @@ class NewlyController:
|
|
352
352
|
self("ZED")
|
353
353
|
|
354
354
|
def _execute_job(self):
|
355
|
+
self.service.laser_status = "active"
|
355
356
|
self("ZED")
|
356
357
|
cmd = b";".join(self._command_buffer) + b";"
|
357
358
|
self.connect_if_needed()
|
358
359
|
self.connection.write(index=self._machine_index, data=cmd)
|
359
360
|
self._command_buffer.clear()
|
360
361
|
self._clear_settings()
|
362
|
+
self.service.laser_status = "idle"
|
361
363
|
|
362
364
|
def open_job(self, job=None):
|
363
365
|
"""
|