Hello, 3D Printing Friends! Today on the BV3D Channel,
we'll learn how to edit and compile the JyersUI Marlin firmware!
Stick around and we'll get into it right after this.
I'm Bryan, and YOU... are watching BV3D!
Hi, welcome back. Hey, if you're new here, and you're wanting to
learn about 3D printing, 3D modeling and other
3D printing-related stuff, start now, by subscribing, and
clicking the bell, so you don't miss anything.
Okay, so today we're going to edit and compile the JyersUI Marlin
firmware, for the Ender 3v2. After I released the video about installing
the JyersUI Marlin firmware, some of you asked if it would work on
an Ender 3v2 printer that you had installed an Ender Extender on.
The Ender Extender products for the v2 can increase the bed size
up to a massive 400 by 400 millimeters,
and the Z height up to a towering 500 millimeters. There are several
kits which fit the v2, and you can check them out at EnderExtender.com.
And the short answer is "Yes, you
CAN use the JyersUI Marlin firmware with the Ender Extender kits, but
the pre-built binary firmware files are all for the stock hardware."
So in order to do this, you'll need to edit the source code, and compile it.
Plus there are other reasons you might want to edit and compile JyersUI for
yourself, even with a stock, or mostly stock printer.
Maybe you want to be able to address the full 235 x 235mm area of the bed,
or you want a 4x4 mesh leveling grid instead of the 3x3 or 5x5 ones in the
pre-built binaries.
There are probably as many reasons as there are people with 3D printers.
So in this video, I'll show you how to change the X, Y, and Z maximum
values, and compile the firmware with those changes.
Now, I thought this was going to be hard to do. I've compiled Marlin before,
but that was the Marlin 1 series,
for the 8-bit boards, and it used the Arduino IDE to do the compilation.
Plus it's been a long time since I did that, and I knew things had
changed, and I knew the tool chain was different, and that meant I'd
have to track down the necessary software to make this work.
Well, I'm happy to report that editing and compiling the JyersUI
Marlin firmware is actually pretty easy.
In fact, it was a lot easier than I thought it was going to be!
Let's get all the necessary software bits together, and then we can
get started. First, we're going to need Visual Studio Code, a free code
editor from Microsoft. You can get it from code.visualstudio.com.
By the way, there are links to everything down in the description.
Once you have VSCode downloaded, install it.
Now I'm making an assumption here, that you know how to install software on your computer.
For VSCode on the Mac, that means unzipping the file and dragging it to the Applications
folder. On Windows, that means doing the thing that Windows makes you do. Same on Linux.
So VSCode is just a code editor. On its own, it's not a development environment. But it
IS extensible. To be able to compile the JyersUI Marlin source code we'll need to
install an extension in VSCode to handle that task.
And that extension is PlatformIO. Installing that is easy. First, launch VSCode. Then,
click the Extensions icon on the left side of the window. It looks like a stack of blocks.
In the Search field, type PlatformIO, and in a few seconds, a list of extensions appears.
At the top of the list is PlatformIO IDE, so click the Install button for PlatformIO IDE.
A few seconds later, it's installed, and its cute little ant-like face appears on the left
side of the window. You can give it a click if you want. And maybe after that, click Open
in the PIO home list.
Of course, we're going to need something for PlatformIO to open, and that something
is the JyersUI Marlin source code. So we'll need to go download that.
Head over to github.com/jyers, and click on the Marlin repository. In there, click
the green Code button, and then click Download ZIP.
Locate the downloaded file. It's named Marlin-Ender_3_V2_JyersUI.zip.
And unzip it. This will result in a folder named Marlin-Ender_3_V2_JyersUI. Move this
folder to your Documents folder, then open the Marlin-Ender_3_V2_JyersUI folder.
If you watched my video about installing
JyersUI, you may remember that there are several different pre-compiled firmware
files that you can pick from, to download and install. These range from just the
basic default JyersUI Marlin firmware, to versions with BL Touch bed probe support,
to Manual Mesh Leveling support, to Universal Bed Leveling support.
Well, inside this folder, there is a Configuration Files folder.
Guess what's inside? That's right! Configuration files!
The ones we are interested in are the ones inside the E3V2 Templates folder.
For the purposes of this video, in which we're going to make changes to
the X, Y, and Z axis maximum values, I'm going to use the Default-NoProbe
configuration files. But, if you're wanting to compile support for a
BLTouch or Manual Mesh Leveling, you'll
use one of these other sets of configuration files. Each of these
template folders contains two configuration files: Configuration.h,
and Configuration_adv.h. Whichever template file you want to use, open
its folder, select the two files within, and copy them. Then, open the Marlin
folder, and paste the files, replacing the two existing configuration files.
Okay, let's check our progress. At this point, we've got VSCode installed.
We've got the PlatformIO extension installed in VSCode.
We've got the JyersUI Marlin source code downloaded.
And we've got the configuration files from the Default-NoProbe template,
parked inside the Marlin folder.
Well now that everything is in place, let's get back to PlatformIO.
Here, from the PlatformIO home screen, click the Open Project button. Navigate
to your Documents folder, and open the Marlin Ender 3v2 JyersUI folder.
The first time you open this, you may be asked to trust the authors of the
files in this folder.
I chose the Yes I Trust The Authors option.
When the folder opens, PlatformIO automatically selects and shows the
platformio.ini file. That's not the file that we need to edit, though, so
click the Marlin folder, here, to expand it. Now with the project opened
in PlatformIO, here are the two
configuration files. And while both of the files from the template folder
needed to be copied and pasted into place, all of the changes that we're
making today happen exclusively in the configuration.h file.
Click the configuration.h file to show its contents. So, let's put ourselves
in the position of a person who has installed an Ender Extender kit, and
now has a 300 by 300mm bed, and a 400mm Z-axis. We are editing the source
code because we want to change the bed size as well as the Z-axis maximum values.
So it's kind of a pain to go scrolling through the file trying to find where
the X_BED_SIZE, Y_BED_SIZE, and the Z-axis maximum position are defined.
It's much easier to simply search for these things, so let's do that. Click the
Edit, menu then click Find. A little Search bar appears over here. Search for
X_BED_SIZE. That will take you to the line in the code where it's defined.
So i'm going to change the value to 300,
to match the physical distance the Ender-extended Ender 3v2 can move along
the X-axis. Conveniently, the Y_BED_SIZE value is right here as well, so I'm going
to change that to 300. And just a few lines down from that, there's the Z_MAX_POS
value. I'll change that to 400. Keep in mind you can set these to whatever you want.
If you're watching this video and you have a stock Ender 3v2, maybe you want to be able
to address the entire 235 x 235mm area of the bed. In that case, you'd set the X and Y
bed sizes to 235. Just remember that if you set them outside the bounds of how far the
printer can actually move, you're going to have a bad time. Or at the very least, your
printer is going to have a bad time.
Oh, and as long as we're in here editing things, you can change the name of the
printer too. Search for CUSTOM_MACINE_NAME, and you'll see that it's set to Ender-3 V2.
If I wanted that to be Bryan's Ender-3 V2, I could change it here. And i think I will.
And that's about it for the editing. Save your changes by clicking the File menu, and
selecting Save. The next step in this process is actually building, or compiling,
the firmware with the changes that we've made. Do that by clicking the check mark
icon, down here at the bottom of the window.
PlatformIO will begin compiling the source code and building the binary file that
we'll load onto the printer. This can take a couple of minutes to complete,
so be patient while it works.
And there, it's done! Right here, just above the Success line, PlatformIO tells
us where it put the binary file.
And it's here. Look in the .PIO/Build folder, and then in the STM32F folder.
The firmware file is the one that starts with "firmware" and ends with "bin"
This folder structure is all within the Marlin-Ender-3-V2 JyersUI folder. On Mac
and Linux machines, files and folders whose names start with a period are
considered "hidden" files. I don't think Windows does this, though.
So for me, the easiest way to get to this folder in my operating system
is to right-click on the firmware.bin file, and click Reveal from the menu.
That will ask the operating system to open the folder this file is in,
and highlight the file for me. Okay. In a previous video, I covered
the steps necessary to flash the JyersUI firmware onto an Ender-3 V2,
including flashing the screen's firmware to give it pretty new icons.
Flashing the screen's firmware isn't required JyersUI will still work just
fine if you don't do it. It just gives you fancy new graphics. If you'd like
detailed instructions on the process, the video is linked down in the
description, and it's also on this card right up here.
But, simply put, the process is:
Copy the firmware.bin file onto a FAT32-formatted MicroSD card,
turn off the printer, insert the card into the printer, and turn
on the printer. When the printer powers up, it checks for the
presence of a firmware file on the card. If it sees one, it'll
install that firmware. The whole process takes about 10 seconds.
Now that it's done, you can see that the custom printer name is
showing up right here on the home screen. And we can check that it
really DID increase the maximum travel distance for X, Y, and Z.
First, looking on the Info menu,
we can see that it shows the build volume as 300 x 300 x 400mm.
And second, it will allow us to enter those maximum values when
attempting to move an axis. Like,
it'll let me request a move of the X-axis up to 300 millimeters.
I'm not going to actually do that move, because the printer can't
physically move the X-axis that far. The stepper motors would hit
the end of their range of motion and just keep on trying, and that's
not good for the motors. Also it makes a REALLY annoying sound.
So...No. Not doing that.
Okay! Now you have the tools to edit and compile the JyersUI
Marlin firmware. And, of course, Marlin firmware in general.
For more information about changes you can make, features you can
enable, and printer behaviors you can modify, I recommend checking
out the JyersUI Github, and the Marlin firmware websites.
Links? Got you covered. Check the description. Since this video deals
specifically with JyersUI, I'll
mention that the JyersUI Github has a Wiki tab with useful information,
and a Discussions tab where you can ask questions about configuring
JyersUI. Of course, it's always a good idea to search there before
you ask. You may find that your question has already been answered!
Well, 3D Printing Friends, that's
about all the time we have for this episode! And now that we're
at the end, let's go print something cool!
Hey, real quick before you go. I wanted to say, "Thanks!" for
being one of the Super Awesome People who sticks around all the
way to the end, and thanks for all the likes, comments, and shares!
And an ESPECIALLY big thanks to
those who directly support what I do. You're all wonderful for
doing that, and I really appreciate it. If you liked this episode, a
thumbs up would be great, and if you'd like to help support the
channel, check the description for ways you can do exactly that.
And hey, if you haven't already subscribed, please do. It's absolutely free, and
it's an excellent way to help keep me making these videos for you.
Well, that's it for this one. Thanks again, and I'll see you next time here,
on the BV3D Channel!