Jump to content

SelectExtruder Plugin in Cura 2.5 Beta 2


cadshef

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

      • UltiMaker Cura 5.8 beta released
        Another Cura release has arrived and in this 5.8 beta release, the focus is on improving Z seams, as well as completing support for the full Method series of printers by introducing a profile for the UltiMaker Method.
          • Like
        • 1 reply
      • Introducing the UltiMaker Factor 4
        We are happy to announce the next evolution in the UltiMaker 3D printer lineup: the UltiMaker Factor 4 industrial-grade 3D printer, designed to take manufacturing to new levels of efficiency and reliability. Factor 4 is an end-to-end 3D printing solution for light industrial applications
          • Thanks
          • Like
        • 3 replies
    ×
    ×
    • Create New...