Redoing stepper motor power feed for X2

Home Model Engine Machinist Forum

Help Support Home Model Engine Machinist Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

idubrov

New Member
Joined
Nov 12, 2013
Messages
3
Reaction score
5
Recently I decided to redo the stepper motor based power feed I had on my X2, for a couple of reasons:

  1. Original feed was done as a separate unit, therefore no single emergency stop.
  2. The enclosure, made from acrylic, had a bunch of cracks. I think, I put too much of internal stress while glueing it.
  3. The controls were small and inconvenient. I don't know what I was thinking
    back when I made the first version. Why would one want a button to switch between "toggle" mode (when you feed and stop by pressing the "feed" button) and "hold" mode (when you feed by holding the "feed" button)? Totally unreasonable. Instead, I want slow/fast feed, as most of the time I prefer to cut in one direction only (don't like chips flying towards me).
  4. I wanted a tachometer.

So, I ended up with a scheme with three control boxes. One box for the power equipment (power supplies and both drivers, one for spindle motor and one for stepper motor). Second box for the controls (I used standard 22mm buttons/lever switch). Third box is for microcontroller, LCD display and rotary encoder.

I decided to only have very basic feed -- no DRO-like features.

The power equipment box is not very well built, I think. Lots of stuff which is probably no-no, like multiple wires in one terminal, too cramped (though I have forced cooling with a small fan), no good separation between noisy wires and signal wires. Actually, when I assembled everything together for the first time, my stepper motor was jerking with spindle motor rotating. Was able to fix it by shortening wires, shielding cables, separating power ground and signal ground, etc. But hey, it works!

It uses STM32 microcontroller which I programmed using language called
"Rust" (I sprayed my mill heavily with LPS 2!). I am pretty happy with it -- I am absolutely not going back to C++!

The PCB I designed myself and ordered online (I'm quite surprised how cheap you can have a factory-made PCB nowadays).

(the source code and PCB design is on the GitHub: https://github.com/idubrov/x2-feed).

See the attached images.

IMG_3200.jpg


IMG_3203.jpg


IMG_3204.JPG


IMG_3202.jpg


IMG_3194.jpg


IMG_3201.jpg
 
And this is the first and second versions I made before.

The first version (cracked one) I used for a few years. It's Arduino-based.

The second box I made for the lathe. It is based on STM32 "Discovery" board, which one would typically use to learn parcticular STM32 microcontroller. I never completed it (it has basic features, like power feed, but no thread cutting). It was over-designed a little: rotary encoder, keypad and buttons, sophisticated menu system with ability to change lot of system parameters (like microsteps, pitch of the leadscrew, etc).

IMG_3155.jpg


IMG_3157.JPG
 
Back
Top