Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
ghost opened this issue Jul 31, 2019 · 4 comments
Open

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

ghost opened this issue Jul 31, 2019 · 4 comments

Comments

@ghost
Copy link

ghost commented Jul 31, 2019

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...

@MoonshineSG
Copy link
Owner

Show me your regex and a sample of your file

@drjrkuhn
Copy link

drjrkuhn commented Dec 2, 2020

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.

@MoonshineSG
Copy link
Owner

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,.*

@drjrkuhn
Copy link

Thanks for the explanation. That worked!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants