CB CNC Part 6 – Installing Stepper Motors and Programming VFD

In the previous videos I completed assembling the x, y and z axis of the lead screw CNC machine, and in this video I will attach and wire the stepper motors, fit a sub waste-board and correctly wire and programme a variable frequency drive to power the 1.5kw water-cooled spindle.

If for any reason you want to skip to a particular stage of the build, the time-codes will be in the description.

So the stepper motors were kindly provided by a company called OMC stepper online for free, and in fairness I was considering buying them as they seemed quite reasonably priced. I have however never used them before, but they have a warehouse here in the UK, so I could have ordered some which would not have any import charges.

They provided me with Nema 23’s which were only a little more powerful than the ones I originally got with the now heavily modified x-carve.

I still don’t want to dismantle that machine as I get the occasional job which I run on it – and I can run these similar motors on my current controller, so I can check they work.

The first thing I need to do is tap the wooden plates with the same thread as the bolts I will be securing the steppers with. I checked that the thread held, and measured the gap.

I then began making the aluminium spacers which the motors will stand on. To do this I cut them out on my table saw sledge – although a mitre block and hacksaw would also suffice.

After filing away any burrs, I began assembling the four motors.

These spacers are 32 mm long and there will be four held between each stepper and its plates.

All the machine screws tighten better than expected, and the only decision I had to make at this point, was which direction to point the stepper cables so they would navigate towards drag chains – which I’ve yet to purchase.

These actually feel surprisingly sturdy and could easily hold larger motors.

I tighten the motor couplers and checked everything turned.

Before I move on with wiring, I will router the mounting holes on what will be the sub waste-board.

I’ve already glued and cut this out from a material called Medite exterior, which I then sprayed with lacquer. This is more durable variety of MDF with keeps its shape, and makes a great material for the sub wastebaord.

It’s normally quite expensive but I happen to find a few pieces. You can however use normal MDF for the sub wasteboard which you can seal with MDF sealer (PVA and water).

Ok that was quite scary, because the bit was so long and as it was plunging to make the through holes, it just wasn’t getting rid of the waste material – the chip, quick enough. I could see a burst of mdf dust coming out every so often, every three or four plunges. Anyway that worked, and now I need to put this on the machine now.

I’m going to change the position of the gantry so it’s facing the same direction as where the stepper motors are. So what I’m going to do is undo these two plates here…

and slide the gantry out, flip it around and install the sub wasteboard. This should make accessing, for any reason, the steppers a lot easier.

I’m just using a cable tie to push the nut through the hole.

I also took some measurement for what will be my sacrificial waste-board which is 350 by 350 mm. Not a bad size for this machines footprint which is around 700mm to 500mm.

I am now returning to the stepper motors, and wiring 4-Pin JST Connector to the wires running of the motors. These will allow me to assemble the machine a little more easily, but also give me the option to dismantle everything when I need.

I wired the female end to the stepper motors, and the male ends to the shielded or screened stepper motor wires.

This process is fiddly to say the least. I held the brass terminal in the jaws of the crimps, pushing the appropriate wire in before tightening the crimping pliers. The brass terminals have a catch which locks into the connector. I found pulling the pin with a long nose pliers helped. I also use heat shrink to cover any exposed wired, neaten up the wiring work and stiffen the connection.

I managed to get some shielded stepper motor wire. I bought quite a bit because this isn’t going to be the only CNC machine I make. And I’m going to wire up the motors now. I don’t have the drag chain so I’m going to have to imagine that in place, so I don’t make the wires too short.

I also noticed something else. Which is, the difference between the wires I have and what I was sent with the original x carve.

Even though mine is technical the same specification, it’s a lot more beefier. And the reason is this is only shielded with foil while this has a braid and foil.  The braid has to be earthed, and I’m not sure if I’ll be able to do this on the current controller because I’m using four pin terminals. But really I need a five pin terminal which I can also connect an earth too.

In any case I’m going to wire these up and turn this machine on.

Always take pictures of what you do. It’s very easy to forget.

This is the left stepper motor and this is the right one over here. This cable is going to run through the aluminium extrusion into a block.

So while I’m wiring everthing up, I’m checking the stepper motors by putting the black and green wire together in this case, and then trying to turn the motor. You can hear a kind of clicking (grinding) noise. When I pull them apart you do not hear it. Then I do it with the white and red wires. In this case, I’ve done something wrong and I can’t get any resistance. So I have to change my wiring.

You can see the problem already, the white wire has come out.

 

There are some specifics to the wiring, and I’m not going to lie, it took me to the last crimp to feel like I might have learnt how to do this correctly.

I’m going to come back to the wiring as I’ve actually placed the red and white one incorrectly in the terminal block in this clip. In any case, you’ll need to use a voltmeter and the method I mentioned to check you have done everything correctly.

If you have and can connect the motors to the controller, this should happen.

Everything moves but the x and y axis are quiet while the z is quite loud. I am not sure once I fill the spindle with cooling liquid whether this will help dampen the noise. I could also spray some expandable foal into the extrusion ends?  Anyway that’s something to discuss in the comment s section.

If you want to know more about the controller I am using – the relevant links will be in the information card.

I’m now going to explain how I wired my VFD, and programmed it to power the spindle. The full story is a little overcomplicated, as I received these items from two different companies who I had decided would unwillingly collaborate.

I took advantage of a lot of misinformation, until it backfired, making this stage of the project last a little too long. So I may end up make a follow up video, but for the meantime I’ll try keep this short.

This VFD is manufactured by a company called NfLiXin, and there is very little secondary information about the product compared to say a Huan Yang VFD.

I received mine which upon examining the instructions, noticed the wiring diagram didn’t correspond with the VFD I had asked for. I refused to use it because I could not find an earth terminal. I highlighted this with pictures and they agreed there had been a mistake. So they sent me another VFD, this time with a sticker containing what seemed like the correct wiring.

It has an earth!

But when I went to turn it on, this happen.

I looked at the instructions a little more closely in case I had misunderstood something, and noticed a breakdown of what different parts of the model number, meant.

I came to the conclusion that both VFD’s should take a 220v power supply and run the 1.5kw spindle.

Whoever had designed this complicated piece of electronics wasn’t stupid, but maybe the people selling it didn’t know too much. Maybe some grumpy technician swapped the stickers on the second VFD, after getting a bollocking for something they had not done wrong?

This is definitely the single phase terminals.

I took the wiring labelling off one of the VFD, and found two screw terminals with earth symbols next to them. This information wasn’t on the instructions but when I checked them with a voltmeter they seemed to be connected.

So at least I can connect the earth wire of the spindle to the earth of the main power supply. I rewired the first VFD and it surprisingly turned on, then the second and that also turned on as well. So I have two variable frequency drive.

I’m going to wire the VFD to a GDZ-80-1.5kw water cooled spindle. I am shielding the cable with tinned copper braid which I also wire to the earth.

I could have used the same wire as I had done with the steppers but as I had already bought some 4 core stuff which needed shielding – and the external braid looked quite cool.

Anyway back to programming the VFD.

This was a day of trial and error. I tried to set the VFD to the parameters of the spindle using an auto-tuning feature but when I did this, it seemed to cap the spindle at around 300hz. I tried to respond to the error messages by changing some settings but those setting seemed now locked.

It took me a while to stumble onto the factory reset procedure, and after that I decided to change parameters manually, going from the lowest possible setting upwards when I was unsure.

Like I mentioned earlier there is very little information or documentation about this particular VFD which is an NFliXin, apart from what was in the manual.

In the end, I watched some alternative VFD videos – documenting the parameters which seemed important and changing the equivalent on my own.

I again hit the same problem as before, capping at 300Hz, which would cut power to the spindle. So I began looking at other parameters, and found the maximum carrier-wave frequency / turning point of carrier-wave frequency– and I set from 2 to 5 Khz. And that seemed to do the trick.

I can now turn on the spindle, and set the speed using this potentiometer.

Anyway I hope that video wasn’t too long or confusing – I had missed some detail out but tried to highlight methods or elements which might save you time if you are in a similar build situation.

I should get my friend who is fluent in Mandarin to help me draft a letter directly to the company, and see if they can recommend the correct setting for the particular spindle I am using.

While I am happy with the stepper motors – and I’ll provide a link to those in the description I would suggest getting a VDF spindle bundle or just using a normal wood working router – if you are considering making your own CNC machine. Anyway two VFD’s was a win for me against cheap marketing. Awooga

In the next video I will wire up the water cooling system for the spindle and connect drag-chains where appropriate.

Don’t forget to sacrifice a thumb to the algorithm gods, and check out the usual links now.

 

If you want to support this channel you can become a paetron, sponsoring future videos and my goal of a fortnightly haircuts and building CNC machines.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s