Mixing Extruder with four Extruders

Hi,
Is it possible with the repetier firmware to use the Mixing Extruder function with 4 extruders and to control 2 heating elements?
I've set mixing extruder = 1 but only three extruders and one heating Element work. 
Greetings Michael

Comments

  • Mixing extruder normally have only one heater and the one defined in extruder 0 is used. Also only one sensor can be used for controlling. If that is the case just connect both heaters to same output if it can handle the load.
    If you can not handle the load with one output and have one sensor, you need to find all occurences where that pin gets set and also set in parallel a second one. You could define it in second extruder in in HAL.cpp just use PWM handler to listen on output of first extruder instead. Also make sure pin is defined as output in setup. That should suffice to do the trick.
  • Okay thanks for the quick reply. I will test this tonight.

    And what about the fourth extruder? Is there a possibility?
  • You can mix up to 6 extruders, so do not understand what you mean with 4th extruder?
  • I have four extruders which work individually for each one of them. However, when I activate Mixing Extruder, only three of the extruders go. The fourth (e3) is not running.
  • I got it right, the mistake was mine. Now all 4 extruders are working. Only with the second heating element I did not get any further. Can you help me here again?
  • So you have 4 nozzles?
    The problem is that real sharing of heaters is only supported for one heater in V1 firmware. And with 4 nozzles it would not be a mixed extruder.

    What you can do for example in this config:
    Extruder 1+2 share heater and Extruder 3+4 share heater.
    Extruder 1: Temp sensor + Heater pin
    Extruder 2: same temp sensor as Extruder 1
    Extruder 3: Temp sensor + Heater pin
    Extruder 4: same temp sensor as Extruder 3

    You can only control temperatures with Extruder 1 and 3, but 2 and 4 will show same temperature.

    In Extruder.cpp you can add after
    void Extruder::setTemperatureForExtruder(float temperatureInCelsius, uint8_t extr, bool beep, bool wait) {
    if(extr == 1) extr = 0;
    if(extr == 3) extr = 2;

    So you can set temperature for second and forth extruder as well and they set it for 1 or 3 then. Makes slicers/hosts happy.


  • We have four extruders, all of which are conveyed into one nozzle.
    Unfortunately I haven't gotten any further yet.
  • So we are back with my first answer/solution:-)

    What about the solution to connect both to heaters to same output? You never said if it would be possible or exceed current limit. Otherwise modify HAL.cpp to write pwm output to second output as well. Hope you understand a bit C++ to do so.
  • edited October 9
    Yeah, I forgot to write that. At the moment we have two heating elements at one exit and that is sufficient from the load point of view. But the print head is a university project and it has a pretty big hotend. With the 2 heaters we need about 30 minutes to reach 200 degrees so we would like to install 2 heaters at the 2nd exit.

    With C++ I know myself only half well but I think I can cope with it if I find the right place. If you could say where in the code it would be great.
  • Ok, quite simpel assign second output to EXT1_HEATER_PIN. In HAL.cpp serach

    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN > -1 && NUM_EXTRUDER > 1 && !MIXING_EXTRUDER
            if ((pwm_pos_set[1] = (pwm_pos[1] & HEATER_PWM_MASK)) > 0)
                WRITE(EXT1_HEATER_PIN, !HEATER_PINS_INVERTED);
    #endif
    and replace with
    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN > -1 && NUM_EXTRUDER > 1
            if ((pwm_pos_set[0] = (pwm_pos[0] & HEATER_PWM_MASK)) > 0)
                WRITE(EXT1_HEATER_PIN, !HEATER_PINS_INVERTED);
    #endif

    and also replace

    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN > -1 && NUM_EXTRUDER > 1 && !MIXING_EXTRUDER
    #if PDM_FOR_EXTRUDER
        pulseDensityModulate(EXT1_HEATER_PIN, pwm_pos[1], pwm_pos_set[1],
                             HEATER_PINS_INVERTED);
        if (pwm_pos_set[1] == pwm_count_heater && pwm_pos_set[1] != HEATER_PWM_MASK)
            WRITE(EXT1_HEATER_PIN, HEATER_PINS_INVERTED);

    with

    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN > -1 && NUM_EXTRUDER > 1 
    #if PDM_FOR_EXTRUDER
        pulseDensityModulate(EXT1_HEATER_PIN, pwm_pos[1], pwm_pos_set[1],
                             HEATER_PINS_INVERTED);
        if (pwm_pos_set[0] == pwm_count_heater && pwm_pos_set[0] != HEATER_PWM_MASK)
            WRITE(EXT1_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif

    That should already do it. Hope you noticed I removed for second extruder the mixing extruder test and changed pwm access from 1 to 0 to use same output signal.
  • I have adapted the code but unfortunately I haven't had any success with it yet.
  • maybe in setup (in printer.cpp) the initialization of the output pin for send one did not happen due to a similar #if test. Then it would not send any signals.
  • You mean this?

    #if defined(EXT0_HEATER_PIN) && EXT0_HEATER_PIN>-1
        SET_OUTPUT(EXT0_HEATER_PIN);
        WRITE(EXT0_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif
    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN>-1 && NUM_EXTRUDER>1
        SET_OUTPUT(EXT1_HEATER_PIN);
        WRITE(EXT1_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif
    #if defined(EXT2_HEATER_PIN) && EXT2_HEATER_PIN>-1 && NUM_EXTRUDER>2
        SET_OUTPUT(EXT2_HEATER_PIN);
        WRITE(EXT2_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif
    #if defined(EXT3_HEATER_PIN) && EXT3_HEATER_PIN>-1 && NUM_EXTRUDER>3
        SET_OUTPUT(EXT3_HEATER_PIN);
        WRITE(EXT3_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif
    #if defined(EXT4_HEATER_PIN) && EXT4_HEATER_PIN>-1 && NUM_EXTRUDER>4
        SET_OUTPUT(EXT4_HEATER_PIN);
        WRITE(EXT4_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif
  • Yes
    #if defined(EXT1_HEATER_PIN) && EXT1_HEATER_PIN>-1 && NUM_EXTRUDER>1
        SET_OUTPUT(EXT1_HEATER_PIN);
        WRITE(EXT1_HEATER_PIN, HEATER_PINS_INVERTED);
    #endif

    should initialize it. EXT1_HEATER_PIN should be set and NUM_EXTRUDER is 4 correct? So no reason to not initialize the pin.

    As a test you can always put a 
    #error compiles
    inside a #if to test. If compilation then fails with that message it would include the code part. Same can be used to test the HAL part.
Sign In or Register to comment.