Jump to content

Servo an J26 Ultimainboard Marlin 1.1.9


Stan-D

Recommended Posts

Posted · Servo an J26 Ultimainboard Marlin 1.1.9

Hallo an alle,

ich bin aktuell mit Marlin 1.1.9 am experimentieren und würde gerne einen Servo über den Anschluss J26 ansteuern, der eine "Switching Nozzle" betätigt.

Komme aber mit der Konfiguration nicht weiter. Hat hier jemand mit der Servoansteuerung und Pinbelegung Erfahrung?

Mit der Programmiersprache bin ich nicht so sehr vertraut, versuche mir jetzt etwas anzueignen...

 

Folgender Fehlermeldung bekomme ich in der ArduinoIDE:

Arduino: 1.8.7 (Mac OS X), Board: "Arduino/Genuino Mega or Mega 2560, ATmega2560 (Mega 2560)"

sketch/Marlin_main.cpp: In function 'void move_nozzle_servo(uint8_t)':
Marlin_main.cpp:12132:53: error: 'MOVE_SERVO' was not declared in this scope
     MOVE_SERVO(SWITCHING_NOZZLE_SERVO_NR, angles[90]);
                                                     ^
exit status 1
'MOVE_SERVO' was not declared in this scope

 

In Configuration.h

// A dual-nozzle that uses a servomotor to raise/lower one of the nozzles
#define SWITCHING_NOZZLE
#if ENABLED(SWITCHING_NOZZLE)
  #define SWITCHING_NOZZLE_SERVO_NR 0
  #define SWITCHING_NOZZLE_SERVO_ANGLES { 0, 90 }   // Angles for E0, E1
  #define HOTEND_OFFSET_Z { 0.0, 0.0 }
#endif

 

#define NUM_SERVOS 1 // Servo index starts with 0 for M280 command

// Delay (in milliseconds) before the next move will start, to give the servo time to reach its target angle.
// 300ms is a good value but you can try less delay.
// If the servo can't reach the requested position, increase it.
#define SERVO_DELAY { 300 }

// Only power servos during movement, otherwise leave off to prevent jitter
#define DEACTIVATE_SERVOS_AFTER_MOVE

 

---------------------------

pins_ULTIMAIN_2.h

 

#define SERVO0_PWM_PIN    13

  • Link to post
    Share on other sites

    Posted · Servo an J26 Ultimainboard Marlin 1.1.9
    15 hours ago, Stan-D said:

    'MOVE_SERVO' was not declared in this scope

     

    Die Fehlermeldung ist ja ziemlich eindeutig. Irgendwo in der Funktion "void move_nozzle_servo(uint8_t)" wird etwas mit dem Namen "MOVE_SERVO" verwendet, das wurde aber nicht gefunden.

     

    Du musst nur herausfinden, was "MOVE_SERVO" ist (vermutlich ein weiteres Makro), und wo das deklariert bzw. definiert ist....

     

    Die aktuelle Marlin-Firmware ist zu großen Teilen aus Makros zusammengesetzt, das ist keine leichte Kost für den Anfang...

     

    Ich hab keine Ahnung, was man für den Servo noch so alles braucht.

    Soweit ich das auf die Schnelle sehen kann, wird "MOVE_SERVO" nur definiert, wenn das Makro "HAS_SERVO" "true" ergibt. Und letzteres prüft u.a., ob mindestens ein Servo-Pin definiert ist.

    Dabei wird allerdings "SERVO0_PIN" geprüft, nicht "SERVO0_PWM_PIN".

    Also vielleicht solltest Du "SERVO0_PIN" (auch) noch definieren, zu "SERVO0_PWM_PIN" hab ich überhaupt nichts gefunden, wird das überhaupt irgendwo benutzt?

     

  • Link to post
    Share on other sites

    Posted · Servo an J26 Ultimainboard Marlin 1.1.9

    Danke für die Antwort!

    Hatte heute Morgen das Problem bereits gefunden. SERVO0_PIN 13 ist richtig, zumindest läuft die Arduino IDE dann durch.

    Ob die Ansteuerung damit geht, habe ich noch nicht ausprobiert...

    Wie bereits erwähnt, habe ich gerade mal ca. 15 Stunden Berührungszeit mit der Programmierung. Überwiegende Zeit war mit den fehlenden Librarys in der IDE verschwendet.

    Wenn ich es richtig verstanden habe, dann sind nur die Winkel über Werkzeug- bzw. Extruderwechsel definiert. PWM-Range entsprechend der Servorichtung bereits als Beispiel vorgelegt. Und schließlich die Ansteuerungszeit in ms für die Dauer der Bewegung.

    Marlin 1.1.9 habe ich auf den Drucker geladen. Originale Menüführung ist gegenüber deinen Versionen ein reinster Krampf!

    Momentan läuft der kleine Lüfter aber nicht mehr beim Aufheizen über 50°C .

  • Link to post
    Share on other sites

    Posted · Servo an J26 Ultimainboard Marlin 1.1.9
    3 hours ago, Stan-D said:

    Momentan läuft der kleine Lüfter aber nicht mehr beim Aufheizen über 50°C

     

    Das hier ist der relevante Teil in der Ultimaker-Firmware, der Kommentar erklärt, warum es so umständlich ist:

    https://github.com/Ultimaker/UM2.1-Firmware/blob/UM2.1_JarJar/Marlin/temperature.cpp#L552

     

    Wenn Du die Ansteuerung vom Servo hinbekommen hast, kannst Du ja mal berichten, wie es funktioniert. Man kann nie wissen, wo man das mal braucht... ?

     

  • Link to post
    Share on other sites

    Posted · Servo an J26 Ultimainboard Marlin 1.1.9

    Hab da endlich eine Anleitung für die Einstellung der Firmware gefunden:

    https://www.thingiverse.com/thing:2777682

    Mal schauen ob die Platine des UM das mitmacht, bzw. die Pinbelegung bei Github richtig hinterlegt sind.

     

    Ich hab mir diese Variante des Druckkopfes anfertigen lassen, nur mit einem Alu-Nocken

    http://www.khwelling.nl/3d.um2_corexy.php

    Umschaltung soll mit dem Servo erfolgen, um möglichst keine unnütze Belastung auf die Riemen zu geben. Und anschließend mit dem Z-Offset beider Düsen die Längendifferenz der einzelnen Düsen aus der Produktion ausgleichen zu können.

  • 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

      • 🎄✨ Thingiverse Tree Ornament Challenge! ✨🎄
        We've been running a Tree Ornament Challenge with a chance to win an UltiMaker S3 or colorFabb filament.
        Design a 3D printable tree ornament and join our festive challenge on Thingiverse. 🎁✨


        📆 Submission Deadline: December 22
        🏷️Tag your designs with Holidays2023

        Click here to join and check out the over 300 other amazing designs

        How to Enter
        Design an Ornament
        Create a 3D printable tree ornament that captures the magic of the winter season. Think snowflakes, sleighs, reindeer, cozy mittens, or anything that embodies the joy of the holidays. Upload to Thingiverse
        Share your masterpiece on Thingiverse and add the tag Holidays2023. Don't forget to include a captivating description and images that showcase your design from different angles. Submit by December 22
        All entries must be submitted by December 22nd to be eligible for consideration.
          Entering a new design
         
        Entering an existing design
         
         
        Winning designs should:
        Be original Creations
        Your designs should be original works, avoiding the use of others' intellectual property without permission. Include STL Files
        Each submission must include at least one STL file for 3D printing. Showcase a Completed Print
        Provide at least one photograph featuring a completed print of your design. Include Documentation
        Share the creative journey! Include documentation of your design process, giving us a peek behind the scenes. For example, show a screenshot of the model in your design program. Use the Tag Holidays2023.
        Use this tag to ensure your entry is counted in the Tree Ornament Challenge. Be submitted after October 1st, 2023
        Ensure your design was uploaded to Thingiverse after October 1st, 2023. Adhere to Submission Guidelines and Terms of Service
        Make sure your submission aligns with our guidelines and Thingiverse's Terms of Service.  
        Good luck 🎉
        • 1 reply
      • S-Line Firmware 8.3.0 was released Nov. 20th on the "Latest" firmware branch.
        (Sorry, was out of office when this released)

        This update is for...
        All UltiMaker S series  
        New features
         
        Temperature status. During print preparation, the temperatures of the print cores and build plate will be shown on the display. This gives a better indication of the progress and remaining wait time. Save log files in paused state. It is now possible to save the printer's log files to USB if the currently active print job is paused. Previously, the Dump logs to USB option was only enabled if the printer was in idle state. Confirm print removal via Digital Factory. If the printer is connected to the Digital Factory, it is now possible to confirm the removal of a previous print job via the Digital Factory interface. This is useful in situations where the build plate is clear, but the operator forgot to select Confirm removal on the printer’s display. Visit this page for more information about this feature.
          • Like
        • 0 replies
      • Ultimaker Cura 5.6 stable released
        Cura now supports Method series printers!
         
        A year after the merger of Ultimaker and MakerBotQQ, we have unlocked the ability for users of our Method series printers to slice files using UltiMaker Cura. As of this release, users can find profiles for our Method and Method XL printers, as well as material profiles for ABS-R, ABS-CF, and RapidRinse. Meaning it’s now possible to use either Cura or the existing cloud-slicing software CloudPrint when printing with these printers or materials
        • 11 replies
    ×
    ×
    • Create New...