Today we're going to talk about how to install a servo on your
Fysetc Spider Version 1.1 now here's the servo type that I found that works best for me now it doesn't
always line up to exactly the zero position due to the ribbing on here so you'll have to adjust
for that in your setup but I'll show you how to actually adjust this angle wise in a second so
let me review a couple of quick things about the servo because it's a little confusing the
wiring down here you can see that it's brown then it's red then it's yellow so the brown is ground
the red is voltage being 5 volts and then the yellow is your signal so in order to set
this up we have to find where our servo pins are which are down in here for the BTLouch
but we need to know which ones they are so what I'm going to do is I'm going to show you how to
check that so if you go over to your desktop on your computer and you go to the GitHub page for
Fysetc you can click on the Fysetc Spider and inside here they have a bunch of information on wiring
but I pulled up a diagram over here so that you can see it more clearly so you can see
that there's a ground voltage and then there's a PA2 let me zoom in a little so you can see this
so then you see ground and then you see another signal pin over here I can't make it out but
we could figure that out inside the pins file essentially these three pins are for your servo
now there are other ways to hook up servos but this is the basic way to do it so I'll
show you how to do this now so if we go over to vs code and we open this up I've already
downloaded and extracted the current Marlin firmware which a current number is 2.0.9.2
so if you click on open folder and you go to your downloads folder your Marlin folder
and then your next Marlin folder you can select the folder there
then what you're going to need to do is go into well first we got to set our default environment
because this is for the MEGA2560 so to figure that out we'll click on the Marlin folder the
source folder the core folder boards.h and we'll search on Spider and as you can see we
have the Spider right here so we'll copy that then we'll close out of core and source in just
a second but let me just point out that the chipset that we're working with is the STM32F4
right here that's our default environment that we need to look up a little bit later but I'm going
to go over to configuration.h and I'm going to set up the motherboard by searching on motherboard
and then I'm going to replace the ramps configuration I'm going to set the serial
port to negative 1. and then what I'm going to do is I'm going to search on num underscore servo
and this will bring us to our servos section so I'll remove the comment with a control slash we
only have one servo so I'm going to change that to a 1 and then what we're going to do is we're going
to set up our build environment so back over here we have the MEGA2560 so we're going to go to the
ini folder that's where all these are pointing to right now and we'll find the STM32F which is our
chipset for an ini file and we'll search on Fysetc and as soon as we find our board which is going
to be down here it's the Fysetc underscore S6 underscore 8000 we'll copy that then we'll go back
over to platformio.ini highlight the MEGA2560 and paste it over that now before we build we do need
to clean out our dot pio folder so we're going to click the little garbage can for clean down here
and now that that's gone we're gonna click on the check box to actually build it so this may take a
few seconds to actually build just keep in mind if it fails the first time click the check box again
because sometimes things build out of order and if you do have it fail after the second time clicking
the check box remember to find the first error that you see in red here and correct that that's
usually what causes the other errors thereafter and the yellow that you just saw go by is actually
a warning it's not a big deal it happens often so now that this is built we're going to click
on the dot pio folder then we're going to go into the Fysetc folder and inside the Fysetc folder we
can see the dot bin so we're going to reveal that in the file explorer but we're going to
go back over to the workbench and set some stuff up because we know where the actual pins are on
the board now because we know that this is going to be ground here voltage and then our PA or PB
pin right here the one that we read off it's already automatically set in our file for our
pins file we're going to take this and we're going to align it such that we can insert it right here
and then we'll have it all configured so now the other thing about this board
that's special for actual servos is that we have to connect power
because this will not run off five volts so I'm going to connect the power with my ferrule cables
so there's one I'll tighten that down and the ferrule cable protects you from
a disastrous situation so I highly recommend getting these these ferrule cables are amazing
because wires will not fray I can't see so let me go over this way the wires won't fray
to touch each other because they're crimped inside it so now that we have that connected what we need
to do is set up the actual build so I'm going to pop out the SD drive I'm going to put it in here
so we can load the actual firmware and place this in the computer which you may hear a beep
now we can go back over to the desktop we can right click on firmware.bin and we can send it
to our drive so on our drive over here you see there's a firmware.bin and an old dot bin when
the firmware.bin finishes loading it's renamed to old.bin so it doesn't reload continuously
so if you ever wanted to reload old.bin or use it for a different printer
you would name it to firmware.bin so what we're going to do now is go back over to the desktop
we're going to pop out the actual drive and we're going to place it inside of here
now normally I would tell you to move the jumper for USB power but we're going to do
it through the power supply so I'm just going to connect this up it won't power the board
and then I'm going to plug it in so I'm going to take the power cord
plug it into the computer or power strip pardon me you'll hear a beep in a second
and then what we'll do is we'll actually go over to Pronterface to test this so let me bring this
up so you can see it so inside of Pronterface obviously we don't know what the COM port is
at the moment and it may show in our actual drop down but I actually want to show you how
to find it real quick so I'm going to click on desktop over here so you can see better
I'm going to then go to device manager I'll bring that up so you can see it and inside
device manager we can see that it's actually com port six that we just connected so what
we can do is we can highlight this then we can backspace and say 6 and then we can say connect
so what you're seeing now is it's connecting and the printer is now online so what we're going to
do is we're actually going to learn to move the servo and that involves a gcode so down in the
bottom right I'm going to type m280 then I'm going to say p and that's the position and it's
the first servo so it's zero because arrays start at zero computer speak then we're going to say s
and this is going to be the angle so we're going to try 45 degrees and see what happens
so let me click on that real quick here so it moves approximately 45 degrees
so let's see if we can do 90 degrees and the reason that it's off is the actual ribs
underneath that little white piece on the servo are causing it to not align
at the actual zero position but you can adjust that with angles so that's why we're doing 90 now
so that one's a little off but we can actually guesstimate what it is by changing the 90 to an
80 and that'll give us our 90 degrees that we're normally looking for so if you want to move back
to zero you can always change s to zero and that'll bring you back to your zero position
so if you like my tutorial please press the like button and subscribe and for my Patrons and
the people on PayPal that like to make donations I'm putting a thank you note at the end of
the tutorial because I'm grateful that you're helping offset the cost to make these tutorials
so everyone take care be safe and have a nice day
you