An Electronic Lead Screw controller using a Teensy 4.1

PCBs from JLCPCB are being shipped. Ordered some GX connectors and some M8 for box to box cables. Need to select some boxes for the electronics. Hopefully I can use some standard open bottom Bud Boxes. Got to get the boxes ordered, stuff is coming in. Then I need to design the panels and connector cut outs. Wow, still a lot of stuff to do.

Received a spare Teensy and a couple of displays, just in case. Fortunately, the supply crisis for Teensy 4.1's has apparently ended. No longer on allocation.

If the first board works, (PCBWay), I will populate the JLCPCB one. Initially, I will socket the first board, because, well, I'm hedging my bets. Pulling a 50 pin through hole part isn't easy! I might solder the board pins with lower melt temp solder. I found some lead free stuff that melts at 137C (278F). That's such a low temp that one could use a hot air gun on the back side and have the part fall out.
 
Found a solution to my problem with coarse threads. I need to up the resolution of the rotary encoder a little bit. Turns out these encoders are still relatively inexpensive even for 1500 pulses per revolution. I have 1024. If I get a 1500 encoder, then I can do 4 TPI threads. So I can do from 4 TPI -100 TPI, and 0.2mm-6mm threads without changing the stepper motor driver. That is good enough.

If I really needed to do 8mm threads, then one would need an encoder marked 1800. But that couldn't do 2 TPI. One would need an encoder that was marked 2500, or 10000 edges per revolution to do 2 TPI at 8 microsteps. Omron does not offer a 2500 rotatory encoder in my 1024 form factor. Interesting trade offs. I will try to get a 1500 encoder. eBay lists some going for $35-$40. That's not bad.

In the meantime, I will limit my threads to 6 TPI and over (0.2 - 5mm).
 
This thread has been great to follow. I have no intention of doing any of it lol, I have a modified Clough42 ELS and love it, but I love watching people develop new stuff like this. You're very thorough.
 
This thread has been great to follow. I have no intention of doing any of it lol, I have a modified Clough42 ELS and love it, but I love watching people develop new stuff like this. You're very thorough.
Thanks for the compliment. Appreciate it.

I might of had a Clough42 system, but there were no boards to buy when I went looking. The supply has returned again. But since I wanted an ELS and there was no controller to buy at the time, I rolled my own. I should have watched more of James' videos, but I confess, I didn't want to be indoctrinated by them. What I did watch was of high value. I browsed his wiki and found it informative. However, I developed all my code independent of his. As it turns out, he borrowed heavily from Didge, as did I.

I added a touch panel display, simply because I disliked James box and its interface. Turns out, it was a good choice, since a touch panel display is quite flexible, because it has programmable context sensitive buttons, that can change size and arrangement as I see fit. The obvious downside is the graphics programming. But I had done some display work on a project about a year ago, and thought the results were worth a try for an ELS.

A lot of this is slog work. Just plugging away at the problem until a satisfactory result occurs. It's amazing how long it takes to stuff all this junk into boxes and cabling it all up nicely. I'm still waiting for stuff to arrive, so things can get packaged properly.
 
Sorry, partly my fault for the supply shortage as I blew one up on my first wiring attempt.

I really need to think about shifting to a touch display - my version has a SECOND interface box, and yeah neither of them are super great (especially my one).
 
May I make a suggestion for future work? Because this is something I added to my ELS, not being sure whether I would use it or not, but it's by fat the most used function for me: electronic stops. On my version, I can set and remove stops (one Left and one Right). The way I've been using it, for example, is to progress the carriage to exactly where I want to turn up to, e.g. the shoulder of the part I'm making. Set my left stop. Jog back to the starting point, set the right stop. Now I can just hit Feed Left, it will feed exactly up to the stop, retract slightly, feed right and it goes "home". Advance the cross slide for the next cut, repeat. I'm absolutely in love with this feature.
 
Sorry, partly my fault for the supply shortage as I blew one up on my first wiring attempt.

I really need to think about shifting to a touch display - my version has a SECOND interface box, and yeah neither of them are super great (especially my one).
No worries about the boards!

Fair warning, the code development for the display took 4 times as much time as for the control for the lead screw. Code wise, there's about 1200 LOC in the display and user interface and only about 250 in the motor control.
 
Here's my additional Clough42 box btw, yeah you can quickly see that a touchscreen display would be a lot nicer than what I've done. In my case the display shows a relative carriage position (calculated) like a budget DRO. Jog "S" changes the jog speed, with 3 selectable speeds.

IMG_20220410_140359.jpg
 
May I make a suggestion for future work? Because this is something I added to my ELS, not being sure whether I would use it or not, but it's by fat the most used function for me: electronic stops. On my version, I can set and remove stops (one Left and one Right). The way I've been using it, for example, is to progress the carriage to exactly where I want to turn up to, e.g. the shoulder of the part I'm making. Set my left stop. Jog back to the starting point, set the right stop. Now I can just hit Feed Left, it will feed exactly up to the stop, retract slightly, feed right and it goes "home". Advance the cross slide for the next cut, repeat. I'm absolutely in love with this feature.
I have been seriously thinking about this. I have DRO inputs on my ELS. Still haven't worked out how to do stops for threading, but feeding should be straight forward. Was toying with how the display would look, and behave for this function, but haven't gotten serious about it yet.

All of this would be a little bit easier, once I get all the loose bits put in a box or two! Once I receive my PCB's I will put a bit more thought into going to a stop. It may require a respin, so I need to think things out a little bit better. The turn time for a PCB is rather long, especially if you are not willing to pay for rush service and delivery.
 
Here's my additional Clough42 box btw, yeah you can quickly see that a touchscreen display would be a lot nicer than what I've done. In my case the display shows a relative carriage position (calculated) like a budget DRO. Jog "S" changes the jog speed, with 3 selectable speeds.

View attachment 420920
Yes, a touch screen would be good for this. A lot more flexible for the design. But very nice job on the box. I can see it is well used. Hope mine turns out to be as useful.
 
Back
Top