Coder Social home page Coder Social logo

davidramiro / marlin-ai3m-2.0.x Goto Github PK

View Code? Open in Web Editor NEW
179.0 30.0 103.0 69.94 MB

šŸ–Ø Marlin 2.0.x optimized for the Anycubic i3 Mega 3D printer

License: GNU General Public License v3.0

C++ 64.99% C 30.11% Makefile 0.28% Objective-C 2.72% Shell 0.67% Python 0.97% CMake 0.06% OpenSCAD 0.08% HTML 0.01% CSS 0.03% JavaScript 0.05% G-code 0.03%
anycubic 3d-printer i3-mega mega-s marlin marlin-firmware firmware

marlin-ai3m-2.0.x's Introduction

Anycubic i3 Mega / Mega-S Marlin 2.0.x by davidramiro

Donate Open Issues Closed Issues Travis CI License

Beta build - use with caution!

This is the newest version of the Marlin Firmware, customized and optimized for the Anycubic i3 Mega, based on my Marlin-Ai3M repository.

While I will try to keep this version updated with the latest changes from the Marlin firmware, for now the old readme and Wiki still applies.


Looking for a BLtouch firmware? Head this way! Mounting and configuration instructions are included.

Make sure to take a look at the Wiki, especially the FAQ.

A German translation of the instructions can be found here.

Why use this?

While the i3 Mega is a great printer for its price and produces fantastic results in stock, there are some improvements and additional features that this firmware provides:

  • Many people have issues getting the Ultrabase leveled perfectly, using Manual Mesh Bed Leveling the printer generates a mesh of the flatness of the bed and compensates for it on the Z-axis for perfect prints without having to level with the screws.
  • Much more efficient bed heating by using PID control. This uses less power and holds the temperature at a steady level. Highly recommended for printing ABS.
  • Fairly loud fans, while almost every one of them is easily replaced, the stock FW only gives out 9V instead of 12V on the parts cooling fan so some fans like Noctua don't run like they should. This is fixed in this firmware.
  • Even better print quality by adding Linear Advance, S-Curve Acceleration and some tweaks on jerk and acceleration.
  • Thermal runaway protection: Reducing fire risk by detecting a faulty or misaligned thermistor.
  • Very loud stock stepper motor drivers, easily replaced by Watterott or FYSETC TMC2208. To do that, you'd usually have to flip the connectors on the board, this is not necessary using this firmware.
  • No need to slice and upload custom bed leveling tests, test it with a single GCode command
  • Easily start an auto PID tune or mesh bed leveling via the special menu (insert SD card, select special menu and press the round arrow)
  • Filament change feature enabled: Switch colors/material mid print (instructions below) and control it via display.
  • The filament runout, pause and stop functionality have been overhauled and improved: The hotend now parks and retracts (on pause or stop) and purges automatically (on resume).
  • Added M888 cooldown routine for the Anycubic Ultrabase (EXPERIMENTAL): This is meant to be placed at the end Gcode of your slicer. It hovers over the print bed and does circular movements while running the fan. Works best with custom fan ducts.
    • Optional parameters:
    • T<temperature>: Target bed temperature (min 15Ā°C), 30Ā°C if not specified (do not set this under room temperature)
    • S<fan speed>: Fan speed between 0 and 255, full speed if not specified
    • e.g. M888 S191 T25: run the fan at 75% until the bed has cooled down to 25Ā°C

Known issues:

  • Power outage support is not included
  • Estimated print times from your slicer might be slightly off.
  • Special characters on any file or folders name on the SD card will cause the file menu to freeze. Simply replace or remove every special character (Chinese, Arabic, Russian, accents, German & Scandinavian umlauts, ...) from the name. Symbols like dashes or underscores are no problem. Important note: On the SD card that comes with the printer there is a folder with Chinese characters in it by default. Please rename or remove it.

How to flash this?

I provided three different precompiled hex files: One for no modifications on the stepper motor drivers - good for people who didn't touch anything yet, one for boards with TMC2208 installed and where the connectors have been flipped and one with TMC2208 and the connectors in original orientation.

Choose your precompiled hex:

  • Download the precompiled firmware here: Releases
  • Choose the correct hex file:
  • For TMC2208 with connectors in original orientation, use Marlin-AI3M-vx.x.x-TMC2208.hex
  • If you use TMC2208 and already reversed your connectors, use Marlin-AI3M-vx.x.x-TMC2208_reversed.hex
  • If you use a newer version of the TMC2208 that doesn't require the connector to be reversed (TMC2208 "v2.0" written on the PCB, chip on the top side), please also use Marlin-AI3M-vx.x.x-TMC2208_reversed.hex.
  • If you use the original stepper motor drivers, use Marlin-AI3M-vx.x.x-stock_drivers.hex.

Or compile it yourself:

  • Download and install Arduino IDE
  • Clone or download this repo
  • Browse into the Marlin folder and run Marlin.ino
  • In the IDE, under Tools -> Board select Genuino Mega 2560 and ATmega2560
  • Open Marlin.ino in the Marlin directory of this repo
  • Customize if needed (e.g. motor directions and type at line 559 to 566 and line 857 to 865 in Configuration.h)
  • Under Sketch, select Export compiled binary
  • Look for the .hex file in the Marlin directory (only use the Marlin.ino.hex, not the Marlin.ino.with_bootloader.hex!)

After obtaining the hex file:

  • Flash the hex with Cura, OctoPrint or similar
  • Use a tool with a terminal (OctoPrint, Pronterface, Repetier Host, ...) to send commands to your printer.
  • Important Connect to the printer and send the following commands:
  • M502 - load hard coded default values
  • M500 - save them to EEPROM

If you are using this on a Mega-S, those two additional commands are necessary:

  • M92 E384 - set correct steps for the new extruder
  • M500 - save them
  • I highly recommend calibrating the extruder.

Calibration and other instructions have been moved to the Wiki.

Manual Mesh Bed Leveling

If you have issues with an uneven bed, this is a great feature.

  • Insert an SD card, enter the print menu.
  • Enter the special menu by selecting it and pressing the round arrow:

Special Menu

  • In this menu, the round arrow is used to execute the command you selected.
  • Preheat the bed to 60Ā°C with this entry: (if you usually print with a hotter bed, use the Anycubic menu)

Preheat bed

  • Level your preheated bed as well as you can with the four screws.
  • Start the mesh leveling:

Start MMBL

  • Your nozzle will now move to the first calibration position.
  • Don't adjust the bed itself with screws, only use software from here on!
  • Use a paper - I recommend using thermopaper like a receipt or baking paper
  • Use the onscreen controls to lower or raise your nozzle until you feel a light resistance: (If you want to send the same command multiple times, select the item again, even though it is still marked red.)

Z axis controls

  • Once finished , move to the next point:

Next mesh point

  • Repeat the last two steps until all 25 points are done.
  • Your printer will beep, wait 20 seconds and then save (the printer will beep once more to confirm):

Save to EEPROM

  • Reboot your printer.

After leveling:

  • To ensure your mesh gets used on every print from now on, go into your slicer settings and look for the start GCode
  • Look for the Z-homing (either just G28 or G28 Z0) command and insert these two right underneath it:
M501
M420 S1
  • Your printer should now correctly print first layers even on a warped bed.
  • When working on the printer, installing a new hotend or nozzle or the bed warping over time, a new Mesh Leveling procedure is recommended.

Manual commands for use with OctoPrint etc.:

  • G29 S1 - Start MMBL
  • G29 S2 - Next Mesh point
  • Raising Z: G91, G1 Z0.02, G90 (one after another, not in one line)
  • Lowering Z: G91, G1 Z-0.02, G90
  • After seeing ok in the console, send M500 to save.

Testing your bed leveling

  • No need to download or create a bed leveling test, simply send those commands to your printer:
G28
G26 C H200 P5 R25 Q4.2 Z4
  • To adjust your filament's needed temperature, change the number of the H parameter
  • Default bed temperature is 60Ā°C, if you need another temperature, add e.g. B80
  • Q parameter sets retraction length in mm, Z sets unretraction.
  • If your leveling is good, you will have a complete pattern of your mesh on your bed that you can peel off in one piece
  • Don't worry if the test looks a bit messy, the important thing is just that the line width is the same all over the mesh
  • Optional: Hang it up on a wall to display it as a trophy of how great your leveling skills are.

M600 Filament Change

M600 Demo

BETA: This now also works without USB printing, via SD & display.

Configuration (only needed once):

  • Send M603 L0 U0 to use manual loading & unloading.
  • Send M603 L538 U555 to use automatic loading & unloading
    • The L and U paramters define the load and unload length in mm. The values above work well on a stock setup, if you modded your extruder, bowden tube or hotend, you might need to adjust those.
  • Save with M500

Filament change process (manual loading):

  • For printing via SD:
    • Place M600 in your GCode at the desired layer
  • For printing via USB:
    • Place M600 in your GCode at the desired layer or send it via terminal
    • Alternatively: Use FilamentChange Pause in the Special Menu
  • The nozzle will park and your printer will beep
    • For safety reasons, the printer will turn off the hotend after 10 minutes. If you see the temperature being under the target:
      • SD printing: Click CONTINUE (only once!) on the screen and wait for the hotend to heat up again.
      • USB printing: Send M108 and wait for the hotend to heat up again.
  • Remove the filament from the bowden tube
  • Insert the new filament right up to the nozzle, just until a bit of plastic oozes out
  • Remove the excess filament from the nozzle with tweezers
  • For printing via SD:
    • Click CONTINUE on the screen
  • For printing via USB:
    • Send M108 via your USB host or use FilamentChange Resume in the Special Menu
    • Note for OctoPrint users: After sending M108, enable the advanced options at the bottom of the terminal and press Fake Acknowledgement

Filament change process (automatic loading):

  • For printing via SD:
    • Place M600 in your GCode at the desired layer
  • For printing via USB:
    • Place M600 in your GCode at the desired layer or send it via terminal
    • Alternatively: Use FilamentChange Pause in the Special Menu
  • The nozzle will park
  • The printer will remove the filament right up to the extruder and beep when finished
    • For safety reasons, the printer will turn off the hotend after 10 minutes. If you see the temperature being under the target:
      • SD printing: Click CONTINUE (only once!) on the screen and wait for the hotend to heat up again.
      • USB printing: Send M108 and wait for the hotend to heat up again.
  • Insert the new filament just up to the end of the bowden fitting, as shown here:

Load Filament

  • For printing via SD:
    • Click CONTINUE on the screen
  • For printing via USB:
    • Send M108 via your USB host or use FilamentChange Resume in the Special Menu
    • Note for OctoPrint users: After sending M108, enable the advanced options at the bottom of the terminal and press Fake Acknowledgement
  • The printer will now pull in the new filament, watch out since it might ooze quite a bit from the nozzle
  • Remove the excess filament from the nozzle with tweezers

Updating

Back up & restore your settings

Some updates require the storage to be cleared (M502), if mentioned in the update log. In those cases, before updating, send M503 and make a backup of all the lines starting with:

M92
G29
M301
M304

After flashing the new version, issue a M502 and M500. After that, enter every line you saved before and finish by saving with M500.

Something went wrong?

No worries. You can easily go back to the default firmware and restore the default settings.

  • Flash the hex file from the manufacturer's website (in case it's offline, I have uploaded the stock firmwares here as well).
  • After flashing, send M502 and M500. Now your machine is exactly as it came out of the box.

Detailed changes:

  • Thermal runaway protection thresholds tweaked
  • Manual mesh bed leveling enabled (check this link to learn more about it)
  • Heatbed PID mode enabled
  • TMC2208 configured in standalone mode
  • Stepper orientation flipped (you don't have to flip the connectors on the board anymore)
  • Linear advance unlocked (Off by default. Research, calibrate and then enable with M900 Kx)
  • S-Curve Acceleration enabled
  • G26 Mesh Validation enabled
  • Some redundant code removed to save memory
  • Minor tweaks on default jerk and acceleration
  • Print statistics enabled (send M78 to read them)
  • M600 filament change feature enabled
    • Implemented easy resume via display
  • Filament runout behaviour tweaked
    • Added purge and retract
    • Move nozzle to park position on runout
    • Prevent false positives by adding a small delay to the sensor
  • Pause and stop behaviour tweaked
  • Added M888 cooldown routine for the Anycubic Ultrabase

Changes by derhopp:

  • 12V capability on FAN0 (parts cooling fan) enabled
  • Buzzer disabled (e.g. startup beep)
  • Subdirectory support: Press the round arrow after selecting a directory
  • Special menu in the SD file menu: Press the round arrow after selecting Special menu

Marlin 2.0

Marlin 2.0 takes this popular RepRap firmware to the next level by adding support for much faster 32-bit and ARM-based boards while improving support for 8-bit AVR boards. Read about Marlin's decision to use a "Hardware Abstraction Layer" below.

Download earlier versions of Marlin on the Releases page.

Building Marlin 2.0

To build Marlin 2.0 you'll need Arduino IDE 1.8.8 or newer or PlatformIO. Detailed build and install instructions are posted at:

Supported Platforms

Platform MCU Example Boards
Arduino AVR ATmega RAMPS, Melzi, RAMBo
Teensy++ 2.0 AT90USB1286 Printrboard
Arduino Due SAM3X8E RAMPS-FD, RADDS, RAMPS4DUE
LPC1768 ARMĀ® Cortex-M3 MKS SBASE, Re-ARM, Selena Compact
LPC1769 ARMĀ® Cortex-M3 Smoothieboard, Azteeg X5 mini, TH3D EZBoard
STM32F103 ARMĀ® Cortex-M3 Malyan M200, GTM32 Pro, MKS Robin, BTT SKR Mini
STM32F401 ARMĀ® Cortex-M4 ARMED, Rumba32, SKR Pro, Lerdge, FYSETC S6
STM32F7x6 ARMĀ® Cortex-M7 The Borg, RemRam V1
SAMD51P20A ARMĀ® Cortex-M4 Adafruit Grand Central M4
Teensy 3.5 ARMĀ® Cortex-M4
Teensy 3.6 ARMĀ® Cortex-M4

Submitting Changes

Marlin Support

For best results getting help with configuration and troubleshooting, please use the following resources:

Credits

The current Marlin dev team consists of:

License

Marlin is published under the GPL license because we believe in open development. The GPL comes with both rights and obligations. Whether you use Marlin firmware as the driver for your open or closed-source product, you must keep Marlin open, and you must provide your compatible Marlin source code to end users upon request. The most straightforward way to comply with the Marlin license is to make a fork of Marlin on Github, perform your modifications, and direct users to your modified fork.

While we can't prevent the use of this code in products (3D printers, CNC, etc.) that are closed source or crippled by a patent, we would prefer that you choose another firmware or, better yet, make your own.

marlin-ai3m-2.0.x's People

Contributors

alexborro avatar anhardt avatar bgort avatar bkubicek avatar bob-the-kuhn avatar boelle avatar croadfeldt avatar daid avatar ejtagle avatar epatel avatar erikzalm avatar fiveangle avatar gmagician avatar insanityautomation avatar jbrazio avatar ludy87 avatar marcio-ao avatar nothinman avatar p3p avatar robbycandra avatar roxy-3d avatar sjasonsmith avatar stv0g avatar tcm0116 avatar teemuatlut avatar thinkyhead avatar thisiskeithb avatar tpruvot avatar wackerbarth avatar wurstnase avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

marlin-ai3m-2.0.x's Issues

[BUG] MAXTEMP trigger when SD-Card print ends

Bug Description

I discovered a bug while printing using the SD-Card feature in the software.

My printer ran fine on your previous Marlin version (1.1.9)

After the upgrade to Marlin 2.0, my printer does not finish print jobs from SD card correctly.
Hoever, When I print using USB Connection, every print works just as expected.

When I monitor the Serial output I get the following response:

SENT: M105 READ: X:86.81 Y:94.96 Z:1.53 E:0.00 Count X:8138 Y:8138 Z:612 READ: ok T:219.79 /220.00 B:74.99 /75.00 @:47 B@:62 READ: X:92.47 Y:88.40 Z:1.53 E:0.00 Count X:7010 Y:7498 Z:612 READ: X:94.28 Y:86.81 Z:1.53 E:0.00 Count X:7398 Y:7072 Z:612 SENT: M105 **READ: TFT Serial Debug: SD print done... J14 READ: DEBUG: AI3M Pause State: 0 READ: Error:MAXTEMP triggered, system stopped! Heater_ID: 0** SENT: M105 READ: Error:Printer halted. kill() called! READ: TFT Serial Debug: Kill command... J11

After that, the printer immediatelly stops.

I am quite sure the connection to the hotend thermistor is not loose.

Any idea what could trigger the kill function?

My Configurations

Link to configuration file: https://cloud.hansen-its.de:443/share.cgi?ssid=0O2KKcb

Steps to Reproduce

Error does not occur while printing via usb (Simplify 3D)
However, the same G-Code does not work when I put it on to SD-Card
Start print using SD-Card

Last few Lines of the G-Code are:

G92 E0.0000 G1 E-7.0000 F3900 ; layer end G91; relative positioning G1 Z5 ;lift Z axis after printing G90; absolute positioning G1 X0 Y195 F2400 ; position for easy part removal M106 S0 ; fan off M104 S0 ; turn off extruder M140 S0 ; turn off bed M84 ; disable motors

The print finishes as expected, but the printhead stays at the object (it does not lift the nozzle after printing) and the build plate is not moved forward.

Expected behavior: [What you expect to happen]
Printer finishes print and does all commands as expected
Actual behavior: [What actually happens]
Printer calls the kill function and stops immediatelly

Additional Information

[BUG] Out of filament sensor does not trigger printing pause

Bug Description

Filament sensor does not pause print. When filament is out of sensor a message is shown on screen but printing goes on normally.

My Configurations

I'm running latest 2.0.x commit [d47dbd5]

Marlin.zip

Steps to Reproduce

  1. Put a piece of filament on sensor to simulate run out.
  2. Start printing as usual
  3. Remove filament from sensor

Expected behavior: I would expect that printing pauses waiting for new filament

Actual behavior: A message is shown on LCD, so sensor works fine. Printing process goes on.

SD Card not read

SD card not read.
I have inserted the following lines from an older pins_Trigorilla_14.h into the new pins_Trigorilla_14.h:
#define BEEPER_PIN 31
#define SDSS 53
#define LED_PIN 13
#define SD_DETECT_PIN 49

now the SD card is read. Maybe you can add that to your version

[BUG] Mega-S hangs after printing interruption: the printer endlessly repeats the last track in the loop, the touch screen does not respond to clicks

Bug Description

Mega-S hangs after printing interruption: the printer endlessly repeats the last track in the loop, the touch screen does not respond to clicks

My Configurations

Anycubic Mega-S in stock configuration.
Mesh Bed Leveling was performed and enabled(M501 and M420 S1).
Linear advance was enabled(M900 K0.65)

Configuration.h:678-690 were commented(all *_DRIVER_TYPE defines)
Configuration.h:1055-1063 were changed according to comments for stock drivers
Everything else corresponds to the 2.0.x branch

Steps to Reproduce

1: run printing any model, wait until printer starts to print it(e.g.: wait second layer printing).
2: Press "STOP" button.

Expected behavior: the printing correctly has stopped, like in stock firmware.

Actual behavior: the printer hangs: it repeats last track in the loop, the touch screen does not respond to clicks. To stop this loop I have to turn off power.

[BUG] Nozzle as Probe

Complier Error by Probe methode ā€žnozzle as Probe or fix mounted Probeā€œ only with the Anycubic i3 Mega Stock Display.
Complier Error:
Anycubic_TFT.cpp zprobe_zoffset was not declared in this scope

bug in operator overloading in Marlin/src/core/types.h

see at MarlinFirmware/Marlin#17826

Description
In the file Marlin/src/core/types.h the operator overloading of operator* and operator/ for struct XYZval had a bug. See for example:

350: FI XYZval operator* (const float &v) const { XYZval ls = *this; ls.x *= v; ls.y *= v; ls.z *= z; return ls; }

here the value of z is not multiplied by v but by z instead.

Benefits
correct operations are ensured

[BUG] Extruder motor looses stepts and stops working

Bug Description

My Configurations

Required: Please include a ZIP file cAfter 2 or 3 layers the extruder motor of my Anycubic I3 Mega S stops working with TMC 2208.
Once installed the firmware, i had to reverse the extruder motor's pin to make it working correctly.
I tried to mash calibrating the printer different times, i checked the Vref of the drivers, i tried to swap the drivers, and i tried lowering the plate manually but the motor keeps loosing steps and than it stops working and i need to reboot the printer to make it work again.
I tried extruding filament with the built-in function and it work properly.
I followed the guide, i sent those commands after installing the firmware:

M502
M500
M92 E384
M203 E30
M204 R1500.00
M500
I calibrated the plate manually, before using the "mash calibration" function but it still doesn't work.
I tried to reduce print speed at 40 mm/s but it still stops working.
Those are the driver i'm using: https://www.amazon.it/dp/B086MYZHD9?psc=1&ref=ppx_yo2ov_dt_b_product_details

I tried to update the firmware to marlin V2 but it has the same error. During a print i noticed that the motor became more noisy for 2 seconds and than it has stopped working again

I tried to sent the command G26 C H200 P5 R25 Q4.2 Z4. It moves the extruder and the plate but it doesn't extrude. When it starts, the stepper looses steps and than it just stops working

Is 0.85 correct for the Vref of all drivers?

[BUG] Is using inject_P() to send commands to the command buffer from the anycubic_TFT.cpp file actually the right way to do this

Bug Description

Understanding that issue #4 will actually make the anycubic_TFT.cpp code command queuing work the same way in Marlin 2.0 as it did in Marlin 1.1.9 it's still worth considering if this is actually the correct way to do this.

Anytime we are injecting commands to the queue (aborting the current queue) we are technically throwing away commands that had been queued in the command queue just prior to our call.

This means that even in the Marlin 1.1.9 code version of the filament runout code exhibits this behaviour. And effectively once the print resumes we could in theory lose whatever commands were in the queue. Granted this is probably a small number of commands but still possible.

What we really need is a way to prevent the queue from accepting any more commands, but still enqueue our commands immediately after the last command in the queue.

Note sure if Marlin has a concept to do this. We need to review the key code to understand if this is even a problem, and if there is even an elegant way to solve this.

Printer crashes on Stop

Just installed version 2.0 on my Anycubic i3 Mega S.

Every time I press the Stop button on the printer, a few more print movements happens and then it continues to repeat moving back and forth on the same spot while retracting and and unretracting. Also, the screen is frozen so my only option is to turn the printer off and on.

[BUG] Replace calls to enqueue_now_P in anycubic_TFT.cpp with inject_P

Bug Description

In your 1.4.6 codebase you use the command enqueue_and_echo_commands_P() to send commands to the printer. From the comments in the code of Marlin 1.1.9 enqueue_and_echo_commands_P() actually aborts the current queue and queues your specified command immediately (see code snippet below). But in your Marlin 2.0 codebase you use the command queue.enqueue_now_P(). But from tracing this funciton it appears that enqueue_now_P() will enqueue this command on the end of the command queue, and if the queue is full (which happens if trying to do anything during an sdcard print) then the function just throws out any commands that don't fit on the queue silently.

The Marlin 2.0 code that does the closest thing to enqueue_and_echo_commands_P() is actually queue.inject_P(). Basically enqueue_now_P() will work for any commands from the TFT executed while the printer is not printing from SDCard (like say performing a bed levelling), but it won't work during an SDcard print.

My Configurations

Unchanged from your repository master

Steps to Reproduce

  1. Install Marlin 2.0 codebase
  2. Do an M502 and M500
  3. Load backed up M92 ,G29, M301, M304 values and store with m500
  4. Feed filament into the extruder but bypass filament sensor
  5. Add a small strip of filament in the filament sensor so that it does indicate filament outage
  6. Start any 3d print
  7. Pull the small strip of filament out of the filament sensor to trigger a filament runout

Expected behavior:

  1. Filament runout beeps
  2. Print head parks
  3. A prompt on screen telling you the filament runout has been triggered

Actual behavior:

  1. Printhead stops moving.
  2. No prompt on screen, no beep and no parked head

Additional Information

Code signature of original call in Marlin 1.1.9

/**
*   Record one or many commands to run from program memory.
*   Aborts the current queue, if any.
*   Note: drain_injected_commands_P() must be called repeatedly to drain the commands afterwards
*/
void enqueue_and_echo_commands_P(const char const pgcode) {

Filament In or Filament remove trough the LCD doesnt work.

Description

Steps to Reproduce

  1. [First Step]
  2. [Second Step]
  3. [and so on...]

Expected behavior: [What you expect to happen]

Actual behavior: [What actually happens]

Additional Information

  • Include a ZIP file containing your Configuration.h and Configuration_adv.h files.
  • Provide pictures or links to videos that clearly demonstrate the issue.
  • See How Can I Contribute for additional guidelines.

ADVANCED_PAUSE_FEATURE: M108 delay

Hi.

I've been using one of your pre-builds for a year, and everything works perfectly, and the M600 does what I expect.

I have cloned the repo to change some options, and when I test it I see that everything is going correctly, but when I pause with M600 and then launch M108, it takes about 10-15 seconds to start loading the filament (once the loading speed is as expected)

My Configurations

#if ENABLED(ADVANCED_PAUSE_FEATURE)
  #define PAUSE_PARK_RETRACT_FEEDRATE         60  // (mm/s) Initial retract feedrate.
  #define PAUSE_PARK_RETRACT_LENGTH            4  // (mm) Initial retract.
                                                  // This short retract is done immediately, before parking the nozzle.
  #define FILAMENT_CHANGE_UNLOAD_FEEDRATE     40  // (mm/s) Unload filament feedrate. This can be pretty fast.
  #define FILAMENT_CHANGE_UNLOAD_ACCEL        25  // (mm/s^2) Lower acceleration may allow a faster feedrate.
  #define FILAMENT_CHANGE_UNLOAD_LENGTH      430  // (mm) The length of filament for a complete unload.
                                                  //   For Bowden, the full length of the tube and nozzle.
                                                  //   For direct drive, the full length of the nozzle.
                                                  //   Set to 0 for manual unloading.
  #define FILAMENT_CHANGE_SLOW_LOAD_FEEDRATE   6  // (mm/s) Slow move when starting load.
  #define FILAMENT_CHANGE_SLOW_LOAD_LENGTH     0  // (mm) Slow length, to allow time to insert material.
                                                  // 0 to disable start loading and skip to fast load only
  #define FILAMENT_CHANGE_FAST_LOAD_FEEDRATE  40  // (mm/s) Load filament feedrate. This can be pretty fast.
  #define FILAMENT_CHANGE_FAST_LOAD_ACCEL     25  // (mm/s^2) Lower acceleration may allow a faster feedrate.
  #define FILAMENT_CHANGE_FAST_LOAD_LENGTH   393  // (mm) Load length of filament, from extruder gear to nozzle.
                                                  //   For Bowden, the full length of the tube and nozzle.
                                                  //   For direct drive, the full length of the nozzle.
  //#define ADVANCED_PAUSE_CONTINUOUS_PURGE       // Purge continuously up to the purge length until interrupted.
  #define ADVANCED_PAUSE_PURGE_FEEDRATE        2  // (mm/s) Extrude feedrate (after loading). Should be slower than load feedrate.
  #define ADVANCED_PAUSE_PURGE_LENGTH          50  // (mm) Length to extrude after loading.
                                                  //   Set to 0 for manual extrusion.
                                                  //   Filament can be extruded repeatedly from the Filament Change menu
                                                  //   until extrusion is consistent, and to purge old filament.
  #define ADVANCED_PAUSE_RESUME_PRIME          0  // (mm) Extra distance to prime nozzle after returning from park.
  //#define ADVANCED_PAUSE_FANS_PAUSE             // Turn off print-cooling fans while the machine is paused.

                                                  // Filament Unload does a Retract, Delay, and Purge first:
  #define FILAMENT_UNLOAD_PURGE_RETRACT       13  // (mm) Unload initial retract length.
  #define FILAMENT_UNLOAD_PURGE_DELAY       3000  // (ms) Delay for the filament to cool after retract.
  #define FILAMENT_UNLOAD_PURGE_LENGTH         8  // (mm) An unretract is done, then this length is purged.
  #define FILAMENT_UNLOAD_PURGE_FEEDRATE      25  // (mm/s) feedrate to purge before unload

  #define PAUSE_PARK_NOZZLE_TIMEOUT          900  // (seconds) Time limit before the nozzle is turned off for safety.
  #define FILAMENT_CHANGE_ALERT_BEEPS         3  // Number of alert beeps to play when a response is needed.
  #define PAUSE_PARK_NO_STEPPER_TIMEOUT           // Enable for XYZ steppers to stay powered on during filament change.

  #define PARK_HEAD_ON_PAUSE                      // Park the nozzle during pause and filament change.
  //#define HOME_BEFORE_FILAMENT_CHANGE           // Ensure homing has been completed prior to parking for filament change

  //#define FILAMENT_LOAD_UNLOAD_GCODES           // Add M701/M702 Load/Unload G-codes, plus Load/Unload in the LCD Prepare menu.
  //#define FILAMENT_UNLOAD_ALL_EXTRUDERS         // Allow M702 to unload all extruders above a minimum target temp (as set by M302)```

**Required:** Please include a ZIP file containing your `Configuration.h` and `Configuration_adv.h` files.

### Steps to Reproduce

<!-- Please describe the steps needed to reproduce the issue -->

1. M600
2. M108


**Expected behavior:** After launching M108, the filament begin to load

**Actual behavior:** 10-15 seconds delayed
[Marlin.zip](https://github.com/davidramiro/Marlin-Ai3M-2.0.x/files/6283722/Marlin.zip)


#### Additional Information

* Provide pictures or links to videos that clearly demonstrate the issue.
* See [How Can I Contribute](#how-can-i-contribute) for additional guidelines.

[ARC SUPPORT not true] (Failure with G2/G3)

Bug Description

Installed to Hex File on a Anycubic Mega-S in wanted to use the Arc Welder plugin which needs Arc Support.
G2/G3 commands give out an error, which should mean that Arc Support isnt enabled at the firmware.
I checked the Code in the Configuration_adv.h file at line 1631 and it looks like it should be enabled.
Are there any additional steps, that need to be made?

LV8729 Stepper driver

Dear David

Maybe you can give some information.

I recently ordered the LV8729 motor driver since I have heard good review about them.

I have installed them on the Z, Z2 & E0.
adjusted their voltage to about 1.100V.

Also made the modifications in the code:

#define Z_DRIVER_TYPE LV8729
#define Z2_DRIVER_TYPE LV8729
#define E0_DRIVER_TYPE LV8729

Also needed to switch the direction on the Z, and E0.
#define INVERT_Z_DIR true
#define INVERT_E0_DIR false

The direction now works fine the problem is that the moments is very slow and I also thing it is not the full movement.

My speculation that since it is by default 1/128 and not 1/16 could maybe cause this issue, but what I dont understand is why since if you define the driver type to be LV8729 it should know that that the stepping is 1/128 and work accordingly
CgAGTFl8LauAKo8xAAVdUtF9gCA957

do you have any clue?
By the way it is not only on the 2.0 firmware it is also shown in the 1.19 firmware

Do I need to modify this as well??
X, Y, Z, E0 [, E1[, E2[, E3[, E4]]]]

#define DEFAULT_AXIS_STEPS_PER_UNIT { 80, 80, 400, 412 }
to:
#define DEFAULT_AXIS_STEPS_PER_UNIT { 80, 80, 3200, 3296}

for Z (since the LV8729 is by default 1/128 according to the default of the main board)
1/16 = 400
1/32 = 800
1/64 = 1600
1/128 = 3200

For E0:
1/16 = 412
1/32 = 824
1/64 = 1648
1/128 = 3296

Is that correct?

What about the speed? they move very slow, will this change also accelerate the speed?

[BUG] (y_min & x_max endstop not detected)

Bug Description

When triggered, both the y_min & x_max endstop do not change state

My Configurations

I'm running latest 2.0.x commit 9b7f0ba, with stock code, no modifications
Moved from Marlin 1.1.9 and there was no problem on that firmware.
Tried to compare both configuration file in the "Endstop" section but without any result

Expected behavior: [Normal Homing of all Axes]

Actual behavior: [Y Axis and the second Z axis keep pushing the rail after reaching the endstop]

[Question] should I change steppers pin before compile?

Hi, Iā€™m a little confused about pins settings in trigorilla_14.h and ramps.h

I see that 1.x version has configuration for z2 stepper in
https://github.com/davidramiro/Marlin-Ai3M/blob/master/Marlin/pins_TRIGORILLA_14.h which corresponding for actual wirings. But in 2.x version I see that e1 has pins that actually wired to z2.

Should I change this setting before compile 2.x version?

And another question is if I want to add additional extruder, what should I change in this files? Is enough to just add e2 block with corresponding pins?

[NO-BUG] Changing Marlin language does not change screen language

Bug Description

Hi, I compiled the .hex file on my own, setting Czech language (#define LCD_LANGUAGE cz). After flashing the firmware and following all the steps in "How to flash this?" section, including sending of M commands, my printer has still original English language. In menu language setting still only switches between English and Chinese. I assume flashing the firmware was successful (no beeps on startup) and "Firmware version V116" in info screen:
LCD

My Configurations

Anycubic Mega-S
Configuration.zip

Steps to Reproduce

  1. Download and configure Marlin-Ai3M-2.0.x
  2. Compile and flash the firmware
  3. M502; M500; M92 E384; M500
  4. Restart printer

Expected behavior:
Czech screen language

Actual behavior: [What actually happens]
English screen language

[BUG] Hot end fan runs only at 100%

Bug Description

Does hot end fan support PWM control? It only blows when fan speed is set to 100%. In any other value fan keeps stopped.

My Configurations

Marlin.zip

Steps to Reproduce

  1. Use slicer to configure fan to be active at different speeds
  2. Send gcode to print

Expected behavior: Fan should adapt its speed to setting

Actual behavior: Fan works only if speed is set to 100%

Additional Information

Fan I use is a 5015 like this: https://es.aliexpress.com/item/4000011565156.html

I'll try to connect an oscilloscope to check if PWM is applied. What setting should I ensure to be activated so that Fan 0 is controlled with PWM?

[FR] Include Piezo Build

Hi David,
first: thanks for your work!

I've some questions:

  • Would you like to include a builds which support the piezo sensor for automatic leveling? (If yes I could prepare PR)
  • You've a travis integration but seems travis does not really build the FW, why are you going this way?

Thanks and greets

Print menu crash

I installed the hex ok and everything worked when i made the mesh. I put 7 files on the sd and when i put the sd in, i can see 3 of the first gcode files. If i move the menu down the firmware freezes.
Whats up with that.

trigorilla stepper assignment Z2/E1?

printer: Anycubic I3 Mega-S (upgraded)
board: 8 bit trigorilla 1.0

I'm running a mixed (tmc2209/A4988) stepper driver configuration (A4988 on extruder). and i am very confused about configuring the steppers.

On a Trigorilla board, the second Z-axis is connected to E1 header

in "Configuration.h" I have

#define X_DRIVER_TYPE  TMC2209_STANDALONE
#define Y_DRIVER_TYPE  TMC2209_STANDALONE
#define Z_DRIVER_TYPE  TMC2209_STANDALONE
#define E0_DRIVER_TYPE A4988
#define E1_DRIVER_TYPE TMC2209_STANDALONE

But when i look into "pins_TRIGORILLA_14.h", E1 is not defined. and Y2 and Z2 have the same pins assigned to them (which actually match E1 header on the board). Mind you, there is no Y2 on a trigorilla, and the second Z is hardwired in parallel).

So should "Configuration.h" have
define Z2_DRIVER_TYPE TMC2209_STANDALONE
or
define E1_DRIVER_TYPE TMC2209_STANDALONE
if you have a 2209 driver on the second Z-axis driver? I believe it is Z2 (according to the pins layout), but that is just plain confusing, as it does not actually matches the silkscreen on the trigorilla pcb.

in vanilla Marlin 2.0, this seems to have been changed, and "pins_TRIGORILLA_14.h" has an include for "pins_RAMPS.h", which has the correct pin assignments for the X, Y, Z, E0 and E1 headers on the trigo board.

Hotend fan only 8V

According to the readme this firmware should put 12V to the hot end cooling fan, However I'm only seeing 8V on the fan output. Is this normal?

Bug: "//#define ARC_SUPPORT" in "conv._adv.h" create compiler error

Servas David!

wenn man ARC_SUPPORT deaktiviert bekommt man einige compiler errors. Hast du was in der planer routine geƤndert?

C:\Users\TheDude\AppData\Local\Temp\cc4G2ake.ltrans1.ltrans.o: In function `GcodeSuite::process_parsed_command(bool)':

<artificial>:(.text+0x6d14): undefined reference to `plan_arc(XYZEval<float> const&, XYval<float> const&, unsigned char)'

collect2.exe: error: ld returned 1 exit status

Lyer Shifting with Ai3M and TMC2209's

Marlin-Ai3M-2.0.x paired with TMC2209s (0.86v current on each, upgraded cooling, stealthchop enabled) causes random Y Layer Shifts (random in both time and direction) using Marlin2-Ai3M-v2.0.0_TMC2208-reversed.hex.
This also is true with "stable" Marlin-Ai3M-v1.4.6-TMC2208_reversed.hex

tried toggling linear advance, tried disabling jerk/accel

Mesh Bed Leveling won't go below endstops

Bug Description

When performing manual bed leveling, if a point on the bed is below the end-stops, the z-axis does not exceed that point so it cannot be leveled giving false level readings.

[BUG] Z position not saving

Bug Description

Hi. I'm unable to set Z position in LCD menu, but also positioning instruction provided in the readme file doesn't work. I have sent those commands, saved, rebooted and Z axis is in the same position as it was - pressing the bed.

My Configurations

Anycubic I3 Mega with Chinese nozzle, which is 2.8mm higher than original.

Steps to Reproduce

a) Change position of Z axis via LCD, save, reboot
b) Send G91, G1, G90, or even M206, M428

Actual behavior: EEPROM is not being overwritten (?)

[BUG] M25 Park and M24 Unpark doesn't work the way it did in Marlin 1.1.9

Bug Description

It would seem that filament runout (and M600 colour change and user initiated pause) is not going to be so simple to implement in anycubic_TFT.cpp for Marlin 2.0. The way the head is parked and unparked from filament runout and user initiated pause has changed in marlin 2.0 for the ADVANCED_PAUSE_FEATURE

We need to rework all pause and restart behaviour to work with the new ADVANCED_PAUSE_FEATURE capability of Marlin 2.0.

I noticed that Marlin 2.0 has an extensible UI concept. It might enable us to integrate our anycubic_TFT code more deeply into the Marlin main loop and events/

See this as the original report: MarlinFirmware/Marlin#12437.

My Configurations

Unchanged from your repository master

Steps to Reproduce

  1. Apply fixes to issue #4 first, so that the filament runout or pause doesn't hang the system
  2. Trigger a filament runout event
  3. Wait for head to park
  4. Load filament in the senor and accept the continue dialog.

Expected behavior:

  1. The head should unpark and print job should continue

Actual behavior: [

  1. Nothing happens the head doesn't move

Additional Information

From observing the terminal during a filament runout and continue it seem the M24 call doesn't do anything. Issuing an M108 down the terminal will actually cause the print head to continue and the printer to continue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    šŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. šŸ“ŠšŸ“ˆšŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ā¤ļø Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.