Marlin 1.1.8 firmware (tested with duplicator v2.1)

2347 views
Skip to first unread message

Fabien Devaux

unread,
Feb 11, 2018, 11:45:53 AM2/11/18
to WanHao Printer 3d
Hi!
I've been experimenting a lot with Marlin lately and got it to work with latest stable.

You can find the patches here: https://github.com/fdev31/Marlin, any feedback is appreciated since I'm new into this.

I also attached the .hex file if you prefer the compiled version.

firmware.hex

banni....@gmail.com

unread,
Feb 11, 2018, 9:28:12 PM2/11/18
to WanHao Printer 3d
Is this a stock compiled version of the Marlin firmware, or were any changes for this compiled one made or any settings specifically designed with the Wanhao i3 in mind?

And if so, are they only for the v2.1 or will this still be viable for older i3 versions?

Fabien Devaux

unread,
Feb 13, 2018, 11:00:14 AM2/13/18
to WanHao Printer 3d
"stock" unconfigured firmware can only run on a specific hardware; I adapted the configuration for melzi board + fixed a few things to make it work on i3 but it's mostly "stock melzi configuration".
Then I added non-hardware related features like mesh bed leveling.

I guess it will work on older i3.

tyler.d...@gmail.com

unread,
Feb 24, 2018, 1:43:23 AM2/24/18
to WanHao Printer 3d
how to flash this to the melzi?
do we just connect it to the usb port to our pc, and upload the firmware hex file via the arduino IDE?


how do we know if the board has a bootloader already?
so we can avoid flashing one.

i got the 2017 V3.5 melzi hybrid board..

neot...@gmail.com

unread,
Mar 21, 2018, 2:58:47 PM3/21/18
to WanHao Printer 3d
I flashed my stock i3 v2 with this, and the temps are off, it's reading 41 degrees at idle, while my IR thermometer says ~23 degrees.

Any ideas? :)

Fabien Devaux

unread,
Mar 21, 2018, 3:06:17 PM3/21/18
to WanHao Printer 3d
Some have "pull-up" resistors and others don't, I suspect this is the difference...
Search "#define TEMP_SENSOR_0 1" in Configuration.h and try different values until it works ;)
I switched my wanhao to RAMPS so I can't really help anymore here...

About the bootloader there are plenty docs on the web!
The simplest is to test flashing a simple example using usb cable & see if it works.

tyler.d...@gmail.com

unread,
Mar 21, 2018, 6:39:05 PM3/21/18
to WanHao Printer 3d
@Fabien Devaux

Does this this marlin fw work, if we don't have any autolevelling probe sensors installed?
since you said you added mesh levelling.

If we upgrade to mks gen 1.4/gen L, can we install this firmware, or do we need to create a new marlin fw for that board?

There is some setting we need to define the
resistor as 4.7k etc to get accurate thermistor reading
for printers that uses that 4.7k resistor.

The default was set at 10k ohm.

Fabien Devaux

unread,
Mar 22, 2018, 9:40:37 AM3/22/18
to WanHao Printer 3d
Hi!
I don't have any probe either, so it's "manual mesh leveling" and it's still super great feature !!

I'm not sure what is mks gen 1.4, but different board = different marlin.

I currently have a RAMPS 1.4 + arduino mega configuration for my i3 and it works pretty well too.

For resistors I don't worry much since I mostly look at which temperature plastic starts melting without trusting much the value....

tyler.d...@gmail.com

unread,
Mar 23, 2018, 6:18:08 PM3/23/18
to WanHao Printer 3d
Can you upload the marlin fw that you created this hex in zip format
so we can edit the resistors ourselves?

The .hex, I think you can't edit the configuration.h

Fabien Devaux

unread,
Mar 23, 2018, 7:32:43 PM3/23/18
to WanHao Printer 3d
It's the first link of the thread. You will find a green button to download as zip.

rapid...@gmail.com

unread,
Mar 29, 2018, 3:40:11 AM3/29/18
to WanHao Printer 3d
can you upload the firmware for Ramps 1.4 + mega + i3

Fabien Devaux

unread,
Mar 29, 2018, 3:36:42 PM3/29/18
to WanHao Printer 3d
Here is the firmware I'm currently using.
I'm still working on it, it works well for me even if the temperature reported is wrong (I changed the thermistor type and kept my old configuration... which is not the most common for wanhao which can provide different pull-up resistor configurations as far as I know).
Please tell me if it works for you, don't hesitate to ask me questions, I can also do different build with another thermistor type if it helps for you, I personally print at lower than expected temperature (at 180 ABS starts melting, at 230° I get robust ABS prints, I guess it's a ~20° offset compared to reality) even if the thermistor shows 60° instead of 20° when the printer is idle.

Enjoy!
firmware.hex

John LeMoine

unread,
May 1, 2018, 6:08:24 AM5/1/18
to WanHao Printer 3d
I tried the firmware on my Maker Select V2 and as with every version of Marlin have the same issue. The display is garbled with missing pixels or pixels flashing on and off. Can't figure it out even went so far as to open the control box to check the connections and all appear fine. I'm going to try and find a copy of the stock firmware and revert back for now until I can figure out a resolution. Running the printer via the USB port works fine, just the display issue that has me puzzled

John LeMoine

unread,
May 2, 2018, 6:46:46 AM5/2/18
to WanHao Printer 3d
update::::  EZABLE Marlin 1.1.8 update on my Maker Select. Well I fixed the display issue. To recap, in preparation on installing my EZable sensor I loaded the Unified TH3D version of Marlin on my Maker Select V2.0 and while every thing ran nomally the display was missing pixels and ghosting to the point of being unusable. Spending days in the forums nothing worked and I was beginning to think is was a hardware issue then I found the fix.. I edited the ultracd_st9720_u8glib_rrd.h file and changed the DELAY 2 from 2 to 5 and reloaded the firmware and it worked perfectly!! #if ENABLED(WANHAO_I3)

#define ST7920_DELAY_1 DELAY_0_NOP
#define ST7920_DELAY_2 DELAY_5_NOP
#define ST7920_DELAY_3 DELAY_0_NOP

Hope this helps anyone else with this what appears to be rare issue

theodore...@gmail.com

unread,
May 17, 2018, 4:27:16 PM5/17/18
to WanHao Printer 3d
Hey, I know you moved on to ramps, but will this firmware work on the MP Maker Select v2? Can I just flash the hex right to the board? Will the temps/steps/etc be correct?

Fabien Devaux

unread,
May 17, 2018, 4:54:23 PM5/17/18
to WanHao Printer 3d
The one here should work if you have the original melzi board.
You can "dump" your current flash to be able to recover it later.... it didn't work for me but in theory it's possible.

If the temp is not correct you can ask here, I can make a few builds with the typical configurations eventually.

If you are interested in the RAMPS adaptation, I can upload the code somewhere.

Scienteer

unread,
May 20, 2018, 2:25:59 AM5/20/18
to WanHao Printer 3d
I have the 1.1.x experimental version running on mine. I wanted to try out the new linear advance(pressure advance) feature. I had just swapped my extruder for a Titan Aero also so needed to flip the E axis in firmware. I did the calibration for the linear advance and discovered that the optimal setting was zero(i.e. disabled). Basically there is so little springyness in the Aero that LA is not required.

It works(but requires a reset after eaxh print). So far I prefer repetier. When 1.1.9 is finally released i might give it a go as they seem to be doing some fundemental mods to the acceleration profiles and timing jitter.

neiljc...@gmail.com

unread,
Jul 29, 2018, 6:59:18 AM7/29/18
to WanHao Printer 3d
I have the Wanhao Duplicator i3 V2.1 and I’ve purchased the MKS Gen L R3 with TMC2208’s and an LV8729 for the Extruder.
What changes to the stock Marlin 1.1.8 firmware do I need to make so it will work? I will be enabling Mesh Bed Leveling, but it’s all the other settings I’m worried about. I upgraded my CR-10S recently and that was easy because I found a step by step guide.
Do you have a build that’s already configured for the MKS Gen L in a Wanhao Duplicator i3 V2 I could download please? I’d be very grateful.
Thank you very much

dlin...@gmail.com

unread,
Sep 23, 2018, 6:49:30 PM9/23/18
to WanHao Printer 3d
You need to add a few nops to the code since it is a timing issue. Try this:

Add 2 nop lines in ultralcd_st7920_u8glib_rrd.h at line 86:

#define ST7920_SND_BIT \
WRITE(ST7920_CLK_PIN, LOW); ST7920_DELAY_1; \
__asm__("nop\n\t"); \
WRITE(ST7920_DAT_PIN, val & 0x80); ST7920_DELAY_2; \
WRITE(ST7920_CLK_PIN, HIGH); ST7920_DELAY_3; \
val <<= 1; \
__asm__("nop\n\t");

Fixed my issue and works great now.

jwn...@gmail.com

unread,
May 24, 2019, 1:49:51 PM5/24/19
to WanHao Printer 3d
I know that this old, but I'm wondering if you figured this out.

I'm having the same issue with Marlin 1.1.9. and incorrect ambient temperature no matter which thermistor I select with TEMP_SENSOR. I even got an upgraded thermistor from Gulf Coast Robotics which specifically says to use TEMP_SENSOR 11, but I still get incorrect ambient temperatures that are high by about 17 degrees Celsius.

Anyone have suggestions? I know there is a place in the configuration that I can set a temperature offset, but that doesn't seem right.

theodore...@gmail.com

unread,
May 24, 2019, 2:04:33 PM5/24/19
to WanHao Printer 3d
Not sure if you got my emails...

I'd honestly get a fresh copy of marlin 1.1.9. Start making the changes you need in a stock rip of it.

But, I actually switched over to Klipper on my melzi, (MP Maker Select v2, bowden, and e3dv6). It is so much nicer.

jwn...@gmail.com

unread,
May 24, 2019, 4:18:25 PM5/24/19
to WanHao Printer 3d
Will try Klipper to see if that is working better. Right now I'm testing prints by setting the temps up 15 degrees.

Do you have a Configuration.h file for the Maker Select V2 for Klipper, or can you let me know what tweaks are needed?

I have an all metal hotend, MOSFET mod, and I bought a BLtouch that I haven't installed yet.

Thanks for the quick reply.

theodore...@gmail.com

unread,
May 24, 2019, 4:25:21 PM5/24/19
to WanHao Printer 3d
Klipper is no walk in the park... It is a fucky firmware that uses a raspberry pi with Octoprint to "stream" gcode.

It pushes an 8bit controller almost up to 32bit speeds. Try printing a circle at .24 layer height, 60+mm/s. The stock controller will stutter, pause and blob like crazy. Klipper has no problem with it.

Watch some youtube videos on klipper, and also they have a premade config file for it.
https://github.com/KevinOConnor/klipper/blob/master/config/printer-wanhao-duplicator-i3-v2.1-2017.cfg

theodore...@gmail.com

unread,
May 24, 2019, 4:28:27 PM5/24/19
to WanHao Printer 3d

testmu...@gmail.com

unread,
Jan 22, 2020, 10:00:06 PM1/22/20
to WanHao Printer 3d
Hello I have downloaded you wanhao i3 ramps marlin and it the steppers seem backwards, like if i trigger endstop z wont move up but it will go down, how would i fix this

niki.ma...@gmail.com

unread,
Mar 8, 2020, 1:51:02 AM3/8/20
to WanHao Printer 3d
I Had this very problem with my X1 and i found that I had the X and Z Axis reversed at the board and it caused that Down but no up on Z That had a melzi V5 in it and that seems almost Identical to my V2 Wanhao i3 (Belco ) which also had a V5.Hope this might help and good luck with it all.

Tom S.

unread,
Apr 10, 2020, 10:51:22 PM4/10/20
to WanHao Printer 3d
So I put the latest Marlin 2.X on my Monoprice clone of the i3 V2 (yes, V2 not 2.1). They have a config for the Wanhao i3 that will work. Two things needed to be changed in the Configuration.h file:

For the LCD to work properly I had to add this line:

#define ST7920_DELAY_2 DELAY_NS(400)

If your ambient temp reads ~40C instead of ~24C then you need to tell it to use a different thermistor calibration. Type 99 will fix this: (also in Configuration.h)

#define TEMP_SENSOR_0 99
#define TEMP_SENSOR_BED 99

It was a beast to compile in the arduino IDE. Be sure to select the 16MHz Atmega1284 and Sanguino as the board type. To get it to compile I had to restart my computer once - the environment got messed up. Be patient.

Also you will need to add a bootloader one time by opening the case and using the ICSP connector. This will blow away the installed firmware on your printer, but you can close up the case and do everything after this with USB. Just don't load a .hex file that 'includes' a boot loader. You already put one on and it will stay installed if you are just updating the firmware via USB.

Also you will want to do PID tuning - it's easy, just google "Marlin PID" and you will get all the info you need.

Good luck - I now have a safer printer with thermal runaway protection!





kei...@gmail.com

unread,
Apr 24, 2020, 8:20:08 PM4/24/20
to WanHao Printer 3d
Thank you!

Adding #define ST7920_DELAY_2 DELAY_NS(400) to my config.h fixed the garbled LCD on my monoprice maker select v2.
Reply all
Reply to author
Forward
0 new messages