Jump to content
Ultimaker Community of 3D Printing Experts

SelectExtruder Plugin in Cura 2.5 Beta 2


Recommended Posts

Posted (edited) · SelectExtruder Plugin in Cura 2.5 Beta 2

Is it possible to use SelectExtruder Plugin in Cura 2.5 Beta 2?

I tried to put the file SelectExtruder.py to the folder C :\Program Files\Cura\Plugins and to the folder

C :\Program Files\Cura\Plugins\PostProcessngPlugin\Scripts, but it does not give a result !

Please help me anybody - how is it correct to set and start Plugin, that Cura saw him?

Edited by Guest
  • Link to post
    Share on other sites
    Posted (edited) · SelectExtruder Plugin in Cura 2.5 Beta 2

    If its a Cura 15.x version plugin, it would have to be rewritten in order to work in Cura 2.x

    If its a Cura 2.x version plugin, it probably just needs to minor changes to make it compatible with Cura 2.5.

    Edited by Guest
  • Link to post
    Share on other sites
    Posted (edited) · SelectExtruder Plugin in Cura 2.5 Beta 2

    I also second this request :-)

    Unfortunately it's an 15.x plugin...

    On the short run you could just manually insert a T1 in the header of the gcode, but to make this plugin working again would be great...

    @DaHai8, is there any chance that you could assist?

    Edited by Guest
  • Link to post
    Share on other sites
    Posted · SelectExtruder Plugin in Cura 2.5 Beta 2

    @DaHai8, is there any chance that you could assist?

     

    Sure, I'd be happy to. Looks like its on GitHub: https://raw.githubusercontent.com/Dim3nsioneer/Cura-Plugins/legacy/SelectExtruder.py

     

    #Name: Select Extruder 15.01#Info: Adjusts the used extruder for a single material print#Help: SelectExtruder#Depend: GCode#Type: postprocess#Param: ExtruderNo(int:0) Extruder to be used (0: 1st ex., 1: 2nd ex.)## Written by Stefan Heule, Dim3nsioneer@gmx.ch## This script is licensed under the Creative Commons - Attribution - Share Alike - Non Commercial (CC BY-SA-NC) 3.0 termsversion = '15.01'import reimport wximport timetry:#MacOS release currently lacks some wx components, like the Publisher.from wx.lib.pubsub import Publisherexcept:Publisher = None

     

    If that's not the right one, let me know.

    I'll start hacking away at it...

  • Link to post
    Share on other sites
    Posted · SelectExtruder Plugin in Cura 2.5 Beta 2

    Ok, here's the converted script. Tested on 2.5.0 Release. I generated some g-code with/without this post-processing-plugin and it appeared to make the correct changes for the extruder number. But I don't have a multi-extruder printer to test with - so Caveat Emptor :)

    You can also download if from here: SelectExtruder.zip

    And pasted below:

     

    #!/usr/bin/env python#Name: Select Extruder 15.01#Info: Adjusts the used extruder for a single material print#Help: SelectExtruder#Depend: GCode#Type: postprocess#Param: ExtruderNo(int:0) Extruder to be used (0: 1st ex., 1: 2nd ex.)# Written by Stefan Heule, Dim3nsioneer@gmx.ch# This script is licensed under the Creative Commons - Attribution - Share Alike - Non Commercial (CC BY-SA-NC) 3.0 terms## Hacked for Cura 2.x by Da Hai Zhu - appologies to the original author# Handles up to 10 extruders (0-9) - should last another year, maybe...# 2017-04-24# version 2.5.0from ..Script import Scriptimport reclass SelectExtruder(Script):   def __init__(self):       super().__init__()   def getSettingDataString(self):       return """{           "name":"Select Extruder",           "key": "SelectExtruder",           "metadata": {},           "version": 2,           "settings":           {               "ext_Num":                {                   "label": "Extruder Number (0 - n)",                   "description": "0 = 1st, 1 = 2nd, etc...",                   "unit": "",                   "type": "int",                   "default_value": 0               }           }       }"""   def execute(self, data):       extNum = self.getSettingValueByKey("ext_Num")       for layer in data:           index = data.index(layer)           lines = layer.split("\n")           for line in lines:               if "M109" in line: #look for M109 command (heat up and wait)                   layer = layer.replace(line, re.sub("M109.+(S\d+)","M109 T%d \g<1>\nT%d\n" % (int(extNum),int(extNum)),line))               elif "M104" in line: #look for M104 command (temperature change)                   layer = layer.replace(line, re.sub("M104.+(S\d+)","M104 T%d \g<1>\nT%d\n" % (int(extNum),int(extNum)),line))               elif re.search("T\d",line) and "M200" not in line:                   layer = layer.replace(line, re.sub("T\d","T%d\n" % int(extNum),line))           data[index] = layer       return data

     

  • Link to post
    Share on other sites
    Posted · SelectExtruder Plugin in Cura 2.5 Beta 2

    DaHai8, thank you very much!

    I will make attempt tomorrow, that turns out with the edited script. About results will write.

    drayson, also thank you for a help!

  • Link to post
    Share on other sites
    Posted (edited) · SelectExtruder Plugin in Cura 2.5 Beta 2

    What does the plugin do?

    Is this still necessary for Cura 2.x?

    Edited by Guest
  • Link to post
    Share on other sites
    Posted · SelectExtruder Plugin in Cura 2.5 Beta 2

    DaHai8, you're THE man - as always :-) Thank you very much, I will give it a try tomorrow afternoon (when my wifey is outa home :-) )

    @ Zerspaner_Gerd, unfortunately yes as there is no option in a dual setup to heat only the one required nozzle and not both. only workaround is to use a single setup for single prints and there is no nozzle selection possible... so thanks to DaHai8's magic there is again the possibility to select the nozzle on a single nozzle print without manual tweaking.

  • Link to post
    Share on other sites

    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now
    • Our picks

      • Talking additive | The 3D printing podcast
        Why should we be the only ones asking questions? Join us and ask Jabil all your questions on September 22nd 5pm CET
          • Like
        • 3 replies
      • Ultimaker masterclass: Optimizing your Ultimaker Cura workflow
        Save your seat for either broadcast on September 23.
        What will you learn?
        · Best practices for iterative print preparation and every lesson you should learn from each print
        · The right way to use per-object settings and when they are most useful
        · Easy-to-use resources for anyone who wants to develop their own printer definitions, plugins, or print profiles
        · How to optimize print profile settings and whether to “keep” or “discard” changes
        · When is the right time to export your drawing from CAD? (Based on Ultimaker Cura’s surprising power as 3D control software)
        · And a whole lot more tips and tricks!
         
        How can I join?
        This free masterclass will take place twice:
        1. 11am CEST (5pm SGT, 5am EDT)
        2. 5pm CEST (11am EDT, 8am PDT, 11pm SGT)
          • Like
        • 0 replies
      • Do you use 3D printing at work? Let us know
        It doesn't matter if you are using 1 Ultimaker or 10, there is inspiration in everything. We're looking for ...
        • 1 reply
    ×
    ×
    • Create New...