OctoPrint-MultiColors icon indicating copy to clipboard operation
OctoPrint-MultiColors copied to clipboard

Printer pauses at 1, 10, 11 ,12, etc.

Open ghost opened this issue 5 years ago • 4 comments

Hey, first of all thanks for the great plugin! Today I found out that if I inject a pause code at layer number 1 it will also inject it at every layer number starting with a 1, eg. 11, 12, 13, etc. stopping at layer number 20.

I guess the code is just looking at the first digit and stops reading thereafter...

ghost avatar Jul 31 '19 14:07 ghost

Show me your regex and a sample of your file

MoonshineSG avatar Jul 31 '19 22:07 MoonshineSG

Great idea for a plugin! But I am seeing the same problem as @TheNewKobra

For Simplify3D, the layers are marked as

; layer 1, Z = 0.240
; layer 2, Z = 0.480
...
; layer 10, Z = 2.400
; layer 11, Z = 2.640
; layer 12, Z = 2.880

I am using the regex string ; layer {layer}.*?. The problem is that I need to include a comma , at the end of the regex pattern to end the match, but that doesn't work. The plugin doesn't find any layer text if I add a comma after with ; layer {layer}.*?,. I am not quite sure how {layer} translates to regex pattern substitution.

drjrkuhn avatar Dec 02 '20 17:12 drjrkuhn

yours shodul workd with ; layer {layer},.* .{layer} gets replaced with the layer number you enter, before the regex is used. So if you look for layer 5, the matching regex will be ; layer 5,.*

MoonshineSG avatar Dec 09 '20 02:12 MoonshineSG

Thanks for the explanation. That worked!

drjrkuhn avatar Dec 23 '20 20:12 drjrkuhn