Specify Settings Layer By Layer

Post Reply
inventabuild
Posts: 271
Joined: 09 Nov 2014, 23:03

Specify Settings Layer By Layer

Post by inventabuild »

Cura has a plugin that allows settings changes based on the layer number or height of the build (see pic). This has come in handy sometimes so I would like to see something like this implemented in KISSlicer and I would like to see the % infill included w/ this option.
Cura - Layer By Layer Settings.PNG
Cura - Layer By Layer Settings.PNG (9.23 KiB) Viewed 3638 times
frankjoke
Posts: 8
Joined: 15 Nov 2014, 11:03

Re: Specify Settings Layer By Layer

Post by frankjoke »

Yes, I used that as well and was writing a postprocessor in Python to do similar things.

In the printer/firmware tab you can post something like:
S:\Downloads\3DPrinter\KissSlicer\Count.py "<FILE>" "-s" "-L2 M221 S100" "-L3 M140 S50"

which would set feed in layer 2 to 100 and bed temperature on layer 3 to 50. It also would sligtly optimize the code and add some M117 text to show where you are on the print (I print offline via OctoPi connected wireless).

All you need is to install Python on the PC.
Attachments
Count.zip
PostProcessorKisslicer
(2.12 KiB) Downloaded 147 times
inventabuild
Posts: 271
Joined: 09 Nov 2014, 23:03

Re: Specify Settings Layer By Layer

Post by inventabuild »

Thanks for the suggestion; however I need to be able to change the layer settings in the slicer because I print from SD card and do not want to be transporting my computer to the printer to update the firmware every time I change print jobs or materials. Also, as a general rule I prefer not to mess with the firmware on a daily basis.

Therefore please let me know if you are talking about putting your code in one of KISSlicer's printer tabs or if you are talking about updating the firmware with your code.
User avatar
Msquare
Posts: 20
Joined: 18 Dec 2014, 12:58
Location: Copenhagen

Re: Specify Settings Layer By Layer

Post by Msquare »

The line the frankjoke suggests goes in the kisslicer field marked PostProcess, which is a line that is issued as a seperate command after slicing, and starts this little program he attached. This program will take the gcode file and edit it - in this case finding the layer comment and add some gcode. If it rewrites the same file or makes a copy is unknown. But at the end, you have a finished gcode file, just like before, but now with the change temperature at the layer. You transfer the gcode to our printer/SDcard like before.
frankjoke
Posts: 8
Joined: 15 Nov 2014, 11:03

Re: Specify Settings Layer By Layer

Post by frankjoke »

Msqare is right with his explanation.

I also do not want to bring/connect computer to printer and therefore I use a small RaspBerry PI (<50€ with wireless module) with software OctoPrintwhich is connected to the printer and with which I can send files to the printer via wireless network and can control printer with every web browser. A similar solution is offered by https://www.astroprint.com/.

Anyhow, the postprocessor is run at the end of Kisslicer automatically and just changes the gcode file from Kisslicer.
User avatar
Msquare
Posts: 20
Joined: 18 Dec 2014, 12:58
Location: Copenhagen

Re: Specify Settings Layer By Layer

Post by Msquare »

Any post processor is a patch/workaround for a missing feature/bug of the main program, and could be included in the main slicer.

Meanwhile, back at the feature request : If one looks at the posts in this topic area, there are several that want something spcial at the first layer, last layer or somewhere. Temperature mostly but something else, too. So a "general" way to specify changes for a few specified is the natural solution. A partial solution is already in the program with the "every N" tab. This just needs to be extended (easy for me to write, I know) to which layernumber it is invoked on. (Messy in the UI, another sublayer of tabs or whatnot). Our great developer has to decide if just doing a "text include" of a M104 S<temp> as now, or to actually have something the influences the slicer algorithms - number of perimeter loops, or skin thickness f.ex - is the way.

So it is not a question of duplicating the cura design, but to enable us to solve a slicing problem : To paraphrase it -"One size" does not fit the whole model
inventabuild
Posts: 271
Joined: 09 Nov 2014, 23:03

Re: Specify Settings Layer By Layer

Post by inventabuild »

frankjoke,

Thank you for the workaround, although it would be nice if Jonathan would upgrade his "N Layers" feature to allow us to change layer values on a "Range of Layers" as Msquare alluded to.

Jonathan, is this easy to do?
User avatar
mhackney
Posts: 147
Joined: 25 Jan 2015, 10:48
Contact:

Re: Specify Settings Layer By Layer

Post by mhackney »

I'm trying to use Count.py on the 1.5 beta 2.7 version on OS X Yosemite and getting an error (code 32512). Here's my post-process execution string:

~MY-USERNAME/Desktop/KISSlicer v1.5 beta 2.7/Count.py "<FILE>" "-v"

I googled the error but could't find anything useful. Anyone running the script on OS X?
User avatar
mhackney
Posts: 147
Joined: 25 Jan 2015, 10:48
Contact:

Re: Specify Settings Layer By Layer

Post by mhackney »

I also just tried this on Windows and get a -1 error. My command there is:

C:\Users\MY_USERNAME\Desktop\KISSlicer\Count.py "<FILE>" "-v"

the file path and case is correct.
User avatar
mhackney
Posts: 147
Joined: 25 Jan 2015, 10:48
Contact:

Re: Specify Settings Layer By Layer

Post by mhackney »

I can run the script direct in Python as:

python Count.py "/Users/MY_USERNAME/Desktop/3DPrinting/Things/Printed Reel/Rev 5.1/gcode/TEST.gcode" "-v"
Post Reply