The synchronization sequence close up, starting @ 14:32, which includes the exact fractions of a second reference, along with a background image of the red LED to allow your brain to comprehend what you are actually seeing is, without a doubt, the highest quality videography work I've ever seen on YT. An extraordinary effort to clarify an important aspect of the gear cutting process. Excellent work Andy.!!
Thanks! That's quite a compliment!! But I think many people could have done it better, I don't even have a high-speed camera, it was filmed at 25 FPS. I felt the graph based explanation just before this, though it did explain what was actually happening, didn't really enable it to be visualised, so I wanted to show it actually working.
I don't have a milling machine or need a gear hobbing attachment but I still enjoyed your video and explanation of how your creation works. You thought of every possibility and made it work. Nice job!
damn dude, you are freaking *amazing!* if you think programming in assembly language is most-ideal, it's no wonder you appear to be able to engineer literally anything.
I don't think i'll ever need one of these but it is jolly decent of you to provide all the documentation and code for free, hats off, and to all the time, thought and effort you have put in to this project👍👍
Well, I built it for myself initially and I've already done all the work, so it doesn't really cost me anything to share it for free. If people appreciate it or can make use of it then they can always contribute something through Patreon or a donation at whatever level they think is appropriate. I prefer this model to charging a fixed price before you get anything and also then I don't feel obligated to provide support or help afterwards (though I always do if I can).
This hobby has some remarkable talent and very generous people, which you are one of. The time and skill set to develop this tool extension for hobby work shop is amazing. I do hope all who down load make a small donation.
Wow! I never expected you to actually do this but I am really glad you did!!! I WILL be making a gear hobbing machine very similar to yours now that I can make a controller for it using your code. Your step by step instructions are awesome, I am somewhat familiar with Arduino stuff in general so this shouldn't be that difficult now that you've done the part that I couldn't do. Also, I will gladly make a donation through your Patreon account as this is the only way I could build a working gear hobbing machine. Thank you so much for doing this, Andy!!!! Looks like it's time to get the 3D printer I've been thinking about. Lol Thanks again, Andy!!! Joe
Glad to hear it! Let me know how it works out. I rarely use my 3D printer for making actual finished things, I got it for making patterns for casting, but I have to say this panel worked out very well and was quick to make. Normally I would have machined the panel and turned or even injection-moulded the buttons, all of which take far longer.
@@AndysMachines Hi Andy, Yeah, my motive for a 3D printer was mainly for casting patterns as well......and maybe a few personalized toys for the grandkids. The Creality UV Resin 3D printer looks pretty inviting to me because of that smooth injection molded look. I have a small control panel for an electronic lead screw on my lathe and the front panel and buttons were 3d printed, that setup replaces the change gears for threading ops with a hybrid stepper motor and I have to say it works very well. The control panel buttons were made very similar to what you have in your new control panel. I'll have to wait until sometime next month to start the hobber project, I'm finishing up a 1969 DoAll Surface grinder rebuild at the moment but the hobber project is now my next project. I think I'll use an Omron Quadrature Rotary Encoder with a 1:1 synchronous drive on top of the milling machine instead of making one as you did, I used an Omron Encoder on the lathe electronic lead screw with good results, I found a source on Ebay for the encoder for less than $45, most places want more than $200 for them. And....I will try making my own gear hobbing cutters after I watch your videos on how to make them another time or two :-) I really, really appreciate what you did here and the fact that you are willing to share it with people like me!! Have a great day!!! Joe
Amazing and, for me, mind boggling. I love your channel and have learned a lot. Thank you for sharing. This is beyond me, but I was able to follow most of it because a few months ago, I started building a Power Feed for the Z-axis on my milling machine using a Stepper motor and driver, controlled by an Arduino. I spent about two months learning how to program the Arduino, and utilized switches, potentiometers, and rotary encoders to accomplish my goal. It's amazing what can be done with a micro-controller. Thank you again. Regards.
I don't even have a milling machine but after stumbling across this looking for mini-lathes/mill reviews for gear hobbing and threading I had to subscribe. The lock picking lawyer joke at the end had me falling out of my chair.
As soon as you said that you feel more comfortable using assembly, I hit the subscribe button. I just knew your content was going to be worthwhile with that comment.
that is incredible, so slick the way you catch when its out of time and bring it right back in, all the error checking, big brain stuff right there, for you not really wanting to use arduino platform you nailed it!
You are a magnificent person for making this available. This is now a project for me- and when I get time to start- I will send a donation your way. There are now at least two people I feel I would like to join patreon to give to and you are one of them. This takes a lot of the difficulty out of hobbing, my hat is off to you 🎩
This is the most amazing use of an Arduino that I have ever seen. The presentation is also outstanding and of top quality. I do not have the machinery to build this for myself but the machine would be a true asset to own.
Good engineers endeavor to optimize their work and I believe that you've done an incredible job with this project. Thank you for publishing it. Though I don't need to hob gears right now, I would definitely use your design in the event that I do.
I've been cutting gears for years, occasionally, with form cutters, but definitely see building this in the near future, much easier to make hobs and get profiled teeth that fit. I completely agree with you.
Excellent project, well though out, thanks for sharing! I, particularly, enjoyed your approach for circumventing the step spindle start. Excellent work
This is very impressive. It also has everything needed to be used as an electronic leadscrew if the code allowed suitable ratio values to be entered. Very well done!
Usually I don't bother if it involves coding but something caught my attention here. Thanks for an excellent presentation, apart from the over dramatic Arduino sound effect, and your offer of all the details for free Is most generous. Thanks Andy, and have a Merry Christmas from Canada's banana belt. ✨👍🇨🇦🤞🌟
I agree 1000% with your thoughts about Arduino & it's ecosystem. While it is good that it simplifies everything, it also brought disadvantages in itself.
I cut gears for a living and use shapers and hobbing machines. For years i always thought about doing something like this but never really had the time to finish my project. I build the closed loop dc motor contoller by missan because they are even cheaper and closed loop and knew the worm will do all the spindle holding anyway. So im guessing you propably going to work on the helical next? Can't wait.... Great work Andy
Yes, a closed loop system would also be a very good way to do it. I'm not familiar with the system you mention, but steppers are pretty cheap these days and I think open-loop stepper is the cheapest and simplest way to do it? This setup can also cut helicals, all you have to do is tilt the hobbing attachment (and adjust the diameter of the blank to suit the helical angle) I covered this in my 2nd video on the hobbing attachment.
Thank you for sharing this project. Your previous 2-part videos inspired me to CNC my rotary table so I can make worm and helical gears for a 3D printed RC car. Only difference is I am going to synchronize my rotary table to both the mill spindle and the X axis DRO scale (both ratios can be adjusted or disabled). That will open the door to making spiral gears like what you would find in a self-centering chuck. Should be a cheaper (and way cooler!) than getting a BS-2 dividing head! Thanks again!
refreshing to see a man who can write some assembly on youtube. cudos. I'm more of a new school guy so I quite like my C for anything where I'm not counting cycles, but even still I prefer reading the datasheet and compiling stuff manually with gcc to avoid the bloat. I also use the stm32 series of microcontrollers for stuff that's more serious, and with the exception of the occasional datasheet errors, I actually find them absolutely great.
Terrific work man!!!!. Finally someone's that is treating Arduino like it deserves. ;-). I'm not sure if you realize what you achieve here. For the Mill its great. But I see an outstanding electronic lead screw for the lathe. Cheap realiable and brilliant. I was already a subscriber but you make me a believer jjajajaja.
Thank you so much for making this video. There was definitely a lot of effort in doing it. You have lots of camera shots, lots of editing capturing lots of detail that would otherwise be hard to see. The panel looks great, no, fantastic, and your flexing buttons are amazing. I am an old-school pic person too. But prior to that, my favorite chip was the 68HC11. I wrote a lot of assembly for that thing including a graphical lcd with manually created fonts and icons using graph paper which was then converted into bits and then into hexadecimal. I’ve wanted to make a hobbing attachment for my mill so this is the perfect marrying of my two interests. I’m so glad you made this video. Happy new year!
When I was learning robotics in high school in the early 2000's we used PIC chips, it was pretty well all we could get that was borderline affordable at that time, and even then the school really didn't want to pay for it, so we ended up all pitching in to pay for a couple programmer boards and each bought our own chips. Arduino really makes it easy compared to how it used to be for us back then!
Andy, if someone in the near future reaches out to you from a little-known start-up called "Skynet", please respond with a Thanks, but not at this time :) Ya, your that good and I'm glad your on our side!
What a great video. I was curious how things would work if there was a timing issue between both spindles. Thanks for sharing this. LOL, at the LPL impersonation. Great stuff.
Fascinating project. I made a Rose engine jig for my wood lathe. I used an Arduino Mega and started with the 2 line display like you used. I found this tedious to program. I changed to using a Nexion touch display. A new learning curve to code, but so much easier using the Nexion editor to create buttons, provide test display etc. The Arduino IDE is not the best, but it works for me. A gear hobbing project is now on my wish list. Thanks for the videos. Dave.
Wow man! This one is really a perfect made project. You thought of everything and made it exactly as it should be. I so rarely see something so finished this days. I also program a few different microcontrollers (STM32, PIC, AVR) and really like Eclipse for it, so if you have some time to spare check out the Sloeber IDE. This one is replacement for Arduino, with a LOT more.
Lol programming an arduino in assembler is knda like rowing the titanic. (The only good thing about the titanic was that it had motors.) 🤣 Nice work on the stepper accel ramping and delayed sync. There was no need for the "spindle * 64 / stepper = whole number" thing. You could have just used a Bresenham ratio accumulator solution which will sync any 2 numbers. It's a fast solution in code, I was doing it in assembler on PICs and steppers back in about 2000. Anyway, cool project and 👍 for making it open source. 🙂
Yes, that's a good analogy. I think arduino programming is kind of like building an Ikea wardrobe. Assembly language is like building the same wardrobe only you have to make every panel and every nut and bolt too. I haven't heard of the Bresenham algorithm before, I'll have to check that out. I just used a simple and fast method that works with most common encoder counts and pulley ratios.
That could be useful for so many more applications than just gear hobbing. It could be used as a rotary welding table or linked with an axis instead of a spindle to make spiral cuts. It could even be used to cut rifling if it were indexed with a purpose built jig or on a machine with long enough of a bed.
Thankyou for the effort and files. It's given me many ideas. I've done many projects with those PICs and found them to be very reliable in noisy applications. The assembly on them is a bit...backward when it comes to operations like subtraction. I think the instructions, the strange memory allocations and the lack of a real stack, puts people off.
13:45 Did you know, that this is how Soyuz aligns with International Space Station for docking ? Because in orbit, speeding up or slowing down changes your own orbit height, you can't just slow down or accelerate to catch the other object, you simply lower or rise your own orbit, which puts you in an orbit faster or slower than the target, you then wait for the orbital offsets to align properly, and then you change the orbit height back, to match the target orbit. Look up the "Hohmann transfer".
Reading through the comments I have to agree with everything I read so far and hit the 'thumbs up' rather than repeat what's already been said. Thanks.
People who choose assembler over the alternatives for hobby projects are the digital equivalent of those that take an axe to the woods and build a cabin... I feel like I need to buy a hat, because you deserve it being tipped, my respect.
Very well done video, your teaching skills are impressive, your technical knowledge is substantial this makes the recipe for a very successful TH-cam channel, please carry on the good work, thank you for sharing your code, so generous of yours, hopefully you will make a video explaining the details of how it functions. Many thanks indeed
Found the avrdude config file under the x86 program files "Arduino\hardware\arduino\tools\avr\bin". I copied the config file as suggested and all ran OK.Thanks Andy!
This is a really well worked out setup. I am impressed with spindle match functionality. That’s the cherry on top of the cake. Also this 3D printed display module is so nice, I can think of a few more projects I am going to use it for. Btw, I’ve used PIC chips long ago and they did the job but I’m lazy and atmega328p works for just about anything I ever intend building.
Thanks! I actually only made the panel 3D printed to make it more accessible for other people to copy, but I was impressed myself by how well it turned out, plus it was quick and easy. PICs are great, but vary hugely in their capabilities, so you do need to choose the right one. The ATmega328 is a much better all-rounder and tends to be my go-to device for almost everything these days.
I recognize that controller!...and now I feel a little old because it was 2014 when I graduated with that degree. Oh well, off to work on my 3rd degree in Jan.
Andy, I just stumbled on your project which seems to provide what I have been looking for. I have a Rivett lathe with its milling attachment. In the catalogue of 1901 there is a nice illustration of using the milling spindle with another attachment that mechanically linked to the nose of the lathe as well as the gear train. It also has a small indexing arrangement. This enables cutting of helical gears with a single tooth cutter running in the milling spindle. It is also capable of milling very long flutes such as drill flutes. Unfortunately this complex attachment is very rare. I have never seen one. I have another lathe with a electronic lead screw and I was thinking about synching of the spindle with the lathe axis when I came across your work. I will need to figure out the best place for the stepper motor. I have a spare encoder that I would rather use than a slotted wheel. They are readily available at reasonable cost. Your videos are excellent and clear I need to study them more. John
"I feel more comfortable with assembly language" -No one ever in the hist...no wait, there's one weird dude who said it This was fucking amazing, though
Hi, excellent video, although you solved the quick start condition in software, which was very clever, a very crude but simple soft start for the motor could be made. If some suitably sized resistors were installed in series with the motor winding it would, on start up, limit the inrush current and the accelerating torque thus increasing the time to get up to speed. The resistor/s would be shorted out with a suitably rated relay or contactor after a preset time of say a couple of seconds. Your solution is clearly more elegant. Again, excellent video.
Thanks! Yes, this motor really does need a soft-start, either that or replace it with a 3-phase motor and inverter. The jolt on startup is causing problems with the gearbox too. It's a twin capacitor motor so I assume it also has a centrifugal switch (though I can't hear it) so maybe all I'd need to do is put a resistor in series with the start capacitor. I'll have to dig deeper.
Ok, first, this is awesome, but second, there is irony in your love for assembly, and your retro video on imperial measurements. That said, I completely agree with you on assembly....I learned in on Z80, and I prefer PICs to the newer microcontrollers. Simpler. Incredibly kind of you to make this public and share the code with everyone, especially as you already had a working model with PIC.
This would be a fantastic macro add on for linux CNC with spindle co-ordination. I am going to build a hob spindle for mc CNC lath that will allow for gear skiving and hobing. Great video !
To solve the spindle lagging with indexer, you must need to replace spindle motor with a high speed and torque stepper or servo motor for spindle, which will eventually remove the lag and work in sync
Hey Andy, thanks for the great content and sharing your designs! I am interested in building one of your controllers for myself, although I have a question before I start. I own a dividing head with 1.8deg motor and 50:1 reduction already and would like to use that. (=10.000 steps/rev) That means I would need a 2.500 CPR Encoder, is this correct and how can I calculate the maximum rpm for my setup so it doesn't exceed the 80kHz limit?
I get this question a lot and it does seem like a quick and easy solution to put a stepper motor on a dividing head/rotary table, but due to the high gear reduction it's usually not a good idea unless you are cutting gears with very large numbers of teeth (like hundreds). To avoid swamping the arduino you'd have to run the mill spindle no faster than 480rpm (60x80Khz/2500x4). But don't forget that also the stepper is going to have to turn 50x faster than the gear blank which is likely to be the limiting factor especially for gears with less than around 30 teeth, most stepper motors have very little torque over 1000rpm. For something like a 10 tooth gear you'd probably have to run the milling machine at less than 100rpm and feed extremely slowly.
@@AndysMachines Thanks a lot, for your reply! I see this is not Ideal, but as I am planning of making just one offs I may give it a try anyways and just cut very slowly.
Completely agree about Arduino! It's popular but extremely limited when used with the IDE. So many projects around the internet end up using multiple arduinos for really simple tasks, and make my inner engineer cringe.
Glad to see you using assembly language. I have used Assembly for over 40 years. I use the 8051 family of processors in aircraft instruments and many other things. Some of the applications are huge 50K lines. We do not have any C in it anywhere. C is too slow and too fat. I have benchmarked C and find it 5-10X slower and bigger. I wrote the assembler too with elaborate functionality for huge programs. It compiles floating point expressions too. I made a hobber 15 years ago too.
I have to agree! There are people who say compiled C is as good or better than assembly written by hand, but it really isn't. The only advantage is it's less effort to write. Plus when writing in assembly you have to learn much more about the specific processor you are using which makes you a better programmer.
I've found that coding in arduino IDE is only good for blinking LED's. As the amount of code grows, using arduino IDE becomes exponentially more frustrating. I'd say after about 300 lines of code arduino IDE becomes unbearable. I personally just code in plain C++ because that's what i grew up with, never really used ASM other than putting an odd NOP line in my C++ code to waste a cycle or two for when i need my peripherals to sync.
Andy I need your help again. I have been trying to find an encoder module like yours for ages now: 4:03. All I can find is very tiny and/or not to spec. Do you have any part number or manufacturing data on said module or can you tell me where to possibly salvage one from? I even tried building my own with two seperate photo transistors. I already made the counting wheel in 2mm thickness and fitted it to my mill to try it with an arduino programmed by my brother which didn't work out on realistic rotational speeds. Unfortunately I seem not to be smart enough to come up with another solution so I try to exactly replicate your setup now with that encoder module being the only thing that is holding me back. Your help would be massively appreciated.
The encoder read head I used came from an unbranded servo motor from some unknown piece of equipment. I used it as the encoder wheel had a fairly coarse resolution that was easy to replicate Look for an Avago/Agilent/HP HEDS encoder read head, these can be found cheap on ebay. They come in different resolutions but if you can find the 'S' option this is 50cpr on a ~25mm wheel which equates to approx 1.5mm line spacing which is quite doable in the home shop, you could probably even 3D print a codewheel with that slot width. (You can of course make the codewheel any size you want as long as you keep the same line spacing.)
@@AndysMachines Now I managed to program the thing but my keypad shield doesn't show any digits. it gets power and the LCD lights up but no individual digits and it doesn't reboot after programming either. I have an Arduino Uno R3 and a shield that looks identical to yours. Any tips?
@@AndysMachines I compared all the pins already and also there are gaps between rows of pins that cannot be plugged in in another way. Ich tested the program too with two switches and toggled them for a few minutes. The motor didn't move so I think the programming in general went wrong somehow even though the command prompt told me it had worked. I don't know if programming with atmel studio could change anything.. I could do that at work.
The synchronization sequence close up, starting @ 14:32, which includes the exact fractions of a second reference, along with a background image of the red LED to allow your brain to comprehend what you are actually seeing is, without a doubt, the highest quality videography work I've ever seen on YT.
An extraordinary effort to clarify an important aspect of the gear cutting process.
Excellent work Andy.!!
Thanks! That's quite a compliment!! But I think many people could have done it better, I don't even have a high-speed camera, it was filmed at 25 FPS.
I felt the graph based explanation just before this, though it did explain what was actually happening, didn't really enable it to be visualised, so I wanted to show it actually working.
I don't have a milling machine or need a gear hobbing attachment but I still enjoyed your video and explanation of how your creation works. You thought of every possibility and made it work. Nice job!
I don't have a milling machine or a gear hobbing attachment but now I need both.
Tggf
ME2 !!👍😉
You just casually programmed the Arduino in assembly language - the whole project is sublime simplicity exemplified, it's magnificent - thank you
damn dude, you are freaking *amazing!* if you think programming in assembly language is most-ideal, it's no wonder you appear to be able to engineer literally anything.
I don't think i'll ever need one of these but it is jolly decent of you to provide all the documentation and code for free, hats off, and to all the time, thought and effort you have put in to this project👍👍
Well, I built it for myself initially and I've already done all the work, so it doesn't really cost me anything to share it for free. If people appreciate it or can make use of it then they can always contribute something through Patreon or a donation at whatever level they think is appropriate. I prefer this model to charging a fixed price before you get anything and also then I don't feel obligated to provide support or help afterwards (though I always do if I can).
Thank you. It was very kind of you to link to the software. Congratulations!
Thanks!
Absolutely brilliantly explain and completed. The whole project is beautiful!
The lag detection and compensation function is very impressive, even moreso in assembly language. Well done!
This hobby has some remarkable talent and very generous people, which you are one of. The time and skill set to develop this tool extension for hobby work shop is amazing. I do hope all who down load make a small donation.
Wow!
I never expected you to actually do this but I am really glad you did!!!
I WILL be making a gear hobbing machine very similar to yours now that I can make a controller for it using your code.
Your step by step instructions are awesome, I am somewhat familiar with Arduino stuff in general so this shouldn't be that difficult now that you've done the part that I couldn't do.
Also, I will gladly make a donation through your Patreon account as this is the only way I could build a working gear hobbing machine.
Thank you so much for doing this, Andy!!!!
Looks like it's time to get the 3D printer I've been thinking about. Lol
Thanks again, Andy!!!
Joe
Glad to hear it! Let me know how it works out.
I rarely use my 3D printer for making actual finished things, I got it for making patterns for casting, but I have to say this panel worked out very well and was quick to make. Normally I would have machined the panel and turned or even injection-moulded the buttons, all of which take far longer.
@@AndysMachines
Hi Andy,
Yeah, my motive for a 3D printer was mainly for casting patterns as well......and maybe a few personalized toys for the grandkids.
The Creality UV Resin 3D printer looks pretty inviting to me because of that smooth injection molded look.
I have a small control panel for an electronic lead screw on my lathe and the front panel and buttons were 3d printed, that setup replaces the change gears for threading ops with a hybrid stepper motor and I have to say it works very well.
The control panel buttons were made very similar to what you have in your new control panel.
I'll have to wait until sometime next month to start the hobber project, I'm finishing up a 1969 DoAll Surface grinder rebuild at the moment but the hobber project is now my next project.
I think I'll use an Omron Quadrature Rotary Encoder with a 1:1 synchronous drive on top of the milling machine instead of making one as you did, I used an Omron Encoder on the lathe electronic lead screw with good results, I found a source on Ebay for the encoder for less than $45, most places want more than $200 for them.
And....I will try making my own gear hobbing cutters after I watch your videos on how to make them another time or two :-)
I really, really appreciate what you did here and the fact that you are willing to share it with people like me!!
Have a great day!!!
Joe
Hola pudiera compartir como lo hizo es exactamente lo q quiero hacer pero tengo poco conocimiento de Arduino y programación etc
Outstanding. All around, wonderful. I appreciate the video and your time/wisdom. Hats off to you !
I've been wondering how to build something like this for a while. Thank you so much for providing this information and making it available to anyone.
Amazing and, for me, mind boggling. I love your channel and have learned a lot. Thank you for sharing. This is beyond me, but I was able to follow most of it because a few months ago, I started building a Power Feed for the Z-axis on my milling machine using a Stepper motor and driver, controlled by an Arduino. I spent about two months learning how to program the Arduino, and utilized switches, potentiometers, and rotary encoders to accomplish my goal. It's amazing what can be done with a micro-controller. Thank you again. Regards.
I don't even have a milling machine but after stumbling across this looking for mini-lathes/mill reviews for gear hobbing and threading I had to subscribe. The lock picking lawyer joke at the end had me falling out of my chair.
As soon as you said that you feel more comfortable using assembly, I hit the subscribe button. I just knew your content was going to be worthwhile with that comment.
that is incredible, so slick the way you catch when its out of time and bring it right back in, all the error checking, big brain stuff right there, for you not really wanting to use arduino platform you nailed it!
You are a magnificent person for making this available. This is now a project for me- and when I get time to start- I will send a donation your way. There are now at least two people I feel I would like to join patreon to give to and you are one of them. This takes a lot of the difficulty out of hobbing, my hat is off to you 🎩
Incredibly nice explanation of how everything works. Lovely implemented "lag" feature!
Incredibly professionally done, thought-out, and explained!!
This is the most amazing use of an Arduino that I have ever seen. The presentation is also outstanding and of top quality. I do not have the machinery to build this for myself but the machine would be a true asset to own.
The references to LPL are hilarious! 😁 You're awesome!
Good engineers endeavor to optimize their work and I believe that you've done an incredible job with this project. Thank you for publishing it. Though I don't need to hob gears right now, I would definitely use your design in the event that I do.
I've been cutting gears for years, occasionally, with form cutters, but definitely see building this in the near future, much easier to make hobs and get profiled teeth that fit. I completely agree with you.
What a clever bloke!
And so generous too.
Excellent project, well though out, thanks for sharing! I, particularly, enjoyed your approach for circumventing the step spindle start. Excellent work
This is very impressive. It also has everything needed to be used as an electronic leadscrew if the code allowed suitable ratio values to be entered. Very well done!
Usually I don't bother if it involves coding but something caught my attention here. Thanks for an excellent presentation, apart from the over dramatic Arduino sound effect, and your offer of all the details for free Is most generous.
Thanks Andy, and have a Merry Christmas from Canada's banana belt.
✨👍🇨🇦🤞🌟
I agree 1000% with your thoughts about Arduino & it's ecosystem. While it is good that it simplifies everything, it also brought disadvantages in itself.
I cut gears for a living and use shapers and hobbing machines. For years i always thought about doing something like this but never really had the time to finish my project. I build the closed loop dc motor contoller by missan because they are even cheaper and closed loop and knew the worm will do all the spindle holding anyway. So im guessing you propably going to work on the helical next? Can't wait.... Great work Andy
Yes, a closed loop system would also be a very good way to do it. I'm not familiar with the system you mention, but steppers are pretty cheap these days and I think open-loop stepper is the cheapest and simplest way to do it?
This setup can also cut helicals, all you have to do is tilt the hobbing attachment (and adjust the diameter of the blank to suit the helical angle) I covered this in my 2nd video on the hobbing attachment.
Thank you for sharing this project. Your previous 2-part videos inspired me to CNC my rotary table so I can make worm and helical gears for a 3D printed RC car. Only difference is I am going to synchronize my rotary table to both the mill spindle and the X axis DRO scale (both ratios can be adjusted or disabled). That will open the door to making spiral gears like what you would find in a self-centering chuck. Should be a cheaper (and way cooler!) than getting a BS-2 dividing head! Thanks again!
Glad to hear it! Yes, that should allow for some interesting operations.
Andy, thank you for the well explained video and the philanthropic gesture of stl's and code.
refreshing to see a man who can write some assembly on youtube. cudos.
I'm more of a new school guy so I quite like my C for anything where I'm not counting cycles, but even still I prefer reading the datasheet and compiling stuff manually with gcc to avoid the bloat.
I also use the stm32 series of microcontrollers for stuff that's more serious, and with the exception of the occasional datasheet errors, I actually find them absolutely great.
and now that I've finished the video, I must say this is very impressive to have been done in assembly.
Terrific work man!!!!. Finally someone's that is treating Arduino like it deserves. ;-).
I'm not sure if you realize what you achieve here.
For the Mill its great. But I see an outstanding electronic lead screw for the lathe. Cheap realiable and brilliant. I was already a subscriber but you make me a believer jjajajaja.
Thank you so much for making this video.
There was definitely a lot of effort in doing it. You have lots of camera shots, lots of editing capturing lots of detail that would otherwise be hard to see. The panel looks great, no, fantastic, and your flexing buttons are amazing. I am an old-school pic person too. But prior to that, my favorite chip was the 68HC11. I wrote a lot of assembly for that thing including a graphical lcd with manually created fonts and icons using graph paper which was then converted into bits and then into hexadecimal.
I’ve wanted to make a hobbing attachment for my mill so this is the perfect marrying of my two interests. I’m so glad you made this video. Happy new year!
When I was learning robotics in high school in the early 2000's we used PIC chips, it was pretty well all we could get that was borderline affordable at that time, and even then the school really didn't want to pay for it, so we ended up all pitching in to pay for a couple programmer boards and each bought our own chips. Arduino really makes it easy compared to how it used to be for us back then!
Andy, if someone in the near future reaches out to you from a little-known start-up called "Skynet", please respond with a Thanks, but not at this time :) Ya, your that good and I'm glad your on our side!
What a great video. I was curious how things would work if there was a timing issue between both spindles. Thanks for sharing this.
LOL, at the LPL impersonation. Great stuff.
Fascinating project. I made a Rose engine jig for my wood lathe. I used an Arduino Mega and started with the 2 line display like you used. I found this tedious to program. I changed to using a Nexion touch display. A new learning curve to code, but so much easier using the Nexion editor to create buttons, provide test display etc.
The Arduino IDE is not the best, but it works for me.
A gear hobbing project is now on my wish list.
Thanks for the videos.
Dave.
Hi again,
Just ordered the needed parts. This will be my second Arduino project (first one was a Mach4 pendant). Cheers.
Amazing, I truly enjoyed these four videos of yours I just have viewed. Thank you for the knowledge kind sir.
I am impressed.
Someone else that.still loves assembly language, and the PIC.
Very nicely designed and built, thank you for sharing, I need to do one for my own, have been putting it off for a couple years. Very nice.
Wow man! This one is really a perfect made project. You thought of everything and made it exactly as it should be. I so rarely see something so finished this days.
I also program a few different microcontrollers (STM32, PIC, AVR) and really like Eclipse for it, so if you have some time to spare check out the Sloeber IDE. This one is replacement for Arduino, with a LOT more.
Lol programming an arduino in assembler is knda like rowing the titanic. (The only good thing about the titanic was that it had motors.) 🤣
Nice work on the stepper accel ramping and delayed sync.
There was no need for the "spindle * 64 / stepper = whole number" thing. You could have just used a Bresenham ratio accumulator solution which will sync any 2 numbers. It's a fast solution in code, I was doing it in assembler on PICs and steppers back in about 2000.
Anyway, cool project and 👍 for making it open source. 🙂
Yes, that's a good analogy. I think arduino programming is kind of like building an Ikea wardrobe. Assembly language is like building the same wardrobe only you have to make every panel and every nut and bolt too.
I haven't heard of the Bresenham algorithm before, I'll have to check that out. I just used a simple and fast method that works with most common encoder counts and pulley ratios.
That could be useful for so many more applications than just gear hobbing. It could be used as a rotary welding table or linked with an axis instead of a spindle to make spiral cuts. It could even be used to cut rifling if it were indexed with a purpose built jig or on a machine with long enough of a bed.
i can envision all the asm questions popping up on the arduino forums due to this! Thanks for sharing.
Thankyou for the effort and files. It's given me many ideas. I've done many projects with those PICs and found them to be very reliable in noisy applications. The assembly on them is a bit...backward when it comes to operations like subtraction. I think the instructions, the strange memory allocations and the lack of a real stack, puts people off.
Nice Job and love the LPL references!
13:45 Did you know, that this is how Soyuz aligns with International Space Station for docking ? Because in orbit, speeding up or slowing down changes your own orbit height, you can't just slow down or accelerate to catch the other object, you simply lower or rise your own orbit, which puts you in an orbit faster or slower than the target, you then wait for the orbital offsets to align properly, and then you change the orbit height back, to match the target orbit. Look up the "Hohmann transfer".
No, I didn't know that. That's very interesting, thanks for that!
Excellent work, sir. Thank you.
Your videos are excellent! Am just getting into machining and appreciate your attitude and approach.
Thanks very much!
Reading through the comments I have to agree with everything I read so far and hit the 'thumbs up' rather than repeat what's already been said. Thanks.
Thanks! I like it when people read the other comments first before asking the same question for the 6th time!! 😁
People who choose assembler over the alternatives for hobby projects are the digital equivalent of those that take an axe to the woods and build a cabin...
I feel like I need to buy a hat, because you deserve it being tipped, my respect.
Brilliant on every level, Andy!
Thanks very much!
Wow - respect. The last MCU I programmed in assembler was 6809 and I had all my teeth and brain cells then ...
Very well done video, your teaching skills are impressive, your technical knowledge is substantial this makes the recipe for a very successful TH-cam channel, please carry on the good work, thank you for sharing your code, so generous of yours, hopefully you will make a video explaining the details of how it functions.
Many thanks indeed
It's working for me, very well. Thank you very much, you best of the best.
Found the avrdude config file under the x86 program files "Arduino\hardware\arduino\tools\avr\bin". I copied the config file as suggested and all ran OK.Thanks Andy!
This is a really well worked out setup. I am impressed with spindle match functionality. That’s the cherry on top of the cake. Also this 3D printed display module is so nice, I can think of a few more projects I am going to use it for. Btw, I’ve used PIC chips long ago and they did the job but I’m lazy and atmega328p works for just about anything I ever intend building.
Thanks! I actually only made the panel 3D printed to make it more accessible for other people to copy, but I was impressed myself by how well it turned out, plus it was quick and easy.
PICs are great, but vary hugely in their capabilities, so you do need to choose the right one. The ATmega328 is a much better all-rounder and tends to be my go-to device for almost everything these days.
wow!! You Are Great!! You Are my Teacher!! You are my Sunshine !!
My dude, you are doing amazing work! And all for free!
That s a very nice work! Thank you very much for sharing your knowledge!
I recognize that controller!...and now I feel a little old because it was 2014 when I graduated with that degree. Oh well, off to work on my 3rd degree in Jan.
Just one word: thanks so much. Thanks for divide your knowledge. I'll trie to make this system based in your explanations.
Nice reference to the LPL at the end! 👌🏻😂
Awesome video. Is the next one covering all the technical details of creation ? That would be very interesting 😊
Andy, I just stumbled on your project which seems to provide what I have been looking for. I have a Rivett lathe with its milling attachment. In the catalogue of 1901 there is a nice illustration of using the milling spindle with another attachment that mechanically linked to the nose of the lathe as well as the gear train. It also has a small indexing arrangement. This enables cutting of helical gears with a single tooth cutter running in the milling spindle. It is also capable of milling very long flutes such as drill flutes. Unfortunately this complex attachment is very rare. I have never seen one. I have another lathe with a electronic lead screw and I was thinking about synching of the spindle with the lathe axis when I came across your work. I will need to figure out the best place for the stepper motor. I have a spare encoder that I would rather use than a slotted wheel. They are readily available at reasonable cost. Your videos are excellent and clear I need to study them more. John
"I feel more comfortable with assembly language"
-No one ever in the hist...no wait, there's one weird dude who said it
This was fucking amazing, though
enjoyed the explanation and video for synchronisation, thanks!
Extremely useful video, thank you for sharing.
Love the shout out to LPL.
Hi, excellent video, although you solved the quick start condition in software, which was very clever, a very crude but simple soft start for the motor could be made. If some suitably sized resistors were installed in series with the motor winding it would, on start up, limit the inrush current and the accelerating torque thus increasing the time to get up to speed. The resistor/s would be shorted out with a suitably rated relay or contactor after a preset time of say a couple of seconds. Your solution is clearly more elegant. Again, excellent video.
Thanks! Yes, this motor really does need a soft-start, either that or replace it with a 3-phase motor and inverter. The jolt on startup is causing problems with the gearbox too. It's a twin capacitor motor so I assume it also has a centrifugal switch (though I can't hear it) so maybe all I'd need to do is put a resistor in series with the start capacitor. I'll have to dig deeper.
Ingenious design!
Thank you for sharing this valuable information . So useful and well explained.
Ok, first, this is awesome, but second, there is irony in your love for assembly, and your retro video on imperial measurements. That said, I completely agree with you on assembly....I learned in on Z80, and I prefer PICs to the newer microcontrollers. Simpler. Incredibly kind of you to make this public and share the code with everyone, especially as you already had a working model with PIC.
I'm glad I watched till the very end. "Nothing on one",🤣🤣🤣😂
This would be a fantastic macro add on for linux CNC with spindle co-ordination. I am going to build a hob spindle for mc CNC lath that will allow for gear skiving and hobing. Great video !
dude, you are amazing!
Outstanding video and professional grade application.
Thank you so much. :-)
Very nicely done. Loved the ending 🤣
To solve the spindle lagging with indexer, you must need to replace spindle motor with a high speed and torque stepper or servo motor for spindle, which will eventually remove the lag and work in sync
Or replace the milling machine motor with an inverter-controlled one with ramp-up😁
@@AndysMachines probably possible
Verry well done!
Definitely want to contribute to your patreon for this awesome project.
Impressive work!
Hey Andy,
thanks for the great content and sharing your designs!
I am interested in building one of your controllers for myself, although I have a question before I start.
I own a dividing head with 1.8deg motor and 50:1 reduction already and would like to use that. (=10.000 steps/rev)
That means I would need a 2.500 CPR Encoder, is this correct and how can I calculate the maximum rpm for my setup so it doesn't exceed the 80kHz limit?
I get this question a lot and it does seem like a quick and easy solution to put a stepper motor on a dividing head/rotary table, but due to the high gear reduction it's usually not a good idea unless you are cutting gears with very large numbers of teeth (like hundreds). To avoid swamping the arduino you'd have to run the mill spindle no faster than 480rpm (60x80Khz/2500x4). But don't forget that also the stepper is going to have to turn 50x faster than the gear blank which is likely to be the limiting factor especially for gears with less than around 30 teeth, most stepper motors have very little torque over 1000rpm. For something like a 10 tooth gear you'd probably have to run the milling machine at less than 100rpm and feed extremely slowly.
@@AndysMachines Thanks a lot, for your reply! I see this is not Ideal, but as I am planning of making just one offs I may give it a try anyways and just cut very slowly.
Thanks Mate
Brilliant work 👍🌺
Completely agree about Arduino! It's popular but extremely limited when used with the IDE. So many projects around the internet end up using multiple arduinos for really simple tasks, and make my inner engineer cringe.
The Arduweeni Wino is a lovely piece of kit imo
Glad to see you using assembly language. I have used Assembly for over 40 years. I use the 8051 family of processors in aircraft instruments and many other things. Some of the applications are huge 50K lines. We do not have any C in it anywhere. C is too slow and too fat. I have benchmarked C and find it 5-10X slower and bigger. I wrote the assembler too with elaborate functionality for huge programs. It compiles floating point expressions too. I made a hobber 15 years ago too.
I have to agree! There are people who say compiled C is as good or better than assembly written by hand, but it really isn't. The only advantage is it's less effort to write. Plus when writing in assembly you have to learn much more about the specific processor you are using which makes you a better programmer.
@@AndysMachines
I have something I would like to send you regarding asm vs C. What is you email?
andysmachines@gmail.com
Big thank you bro. (from thailand)😊😊😊
I've found that coding in arduino IDE is only good for blinking LED's. As the amount of code grows, using arduino IDE becomes exponentially more frustrating. I'd say after about 300 lines of code arduino IDE becomes unbearable.
I personally just code in plain C++ because that's what i grew up with, never really used ASM other than putting an odd NOP line in my C++ code to waste a cycle or two for when i need my peripherals to sync.
This is pretty clever
Thank you so much 🙏 best Christmas ever
Merry Christmas!
Thanks for putting this together!
This is pretty damn awesome
Very Nice! Thank you for sharing.
I've sometimes thought about learning assembly language, but where to start?
This project has me thinking again.
Hey Super thanks for the video and upload. Can it also be used for treading in lathe.. 💪💪
It's actually a very similar setup to an electronic leadscrew for lathe use, it would only need a small change to the software.
Very impressive, thanks for sharing!
Andy I need your help again. I have been trying to find an encoder module like yours for ages now: 4:03. All I can find is very tiny and/or not to spec. Do you have any part number or manufacturing data on said module or can you tell me where to possibly salvage one from? I even tried building my own with two seperate photo transistors. I already made the counting wheel in 2mm thickness and fitted it to my mill to try it with an arduino programmed by my brother which didn't work out on realistic rotational speeds. Unfortunately I seem not to be smart enough to come up with another solution so I try to exactly replicate your setup now with that encoder module being the only thing that is holding me back. Your help would be massively appreciated.
The encoder read head I used came from an unbranded servo motor from some unknown piece of equipment. I used it as the encoder wheel had a fairly coarse resolution that was easy to replicate
Look for an Avago/Agilent/HP HEDS encoder read head, these can be found cheap on ebay. They come in different resolutions but if you can find the 'S' option this is 50cpr on a ~25mm wheel which equates to approx 1.5mm line spacing which is quite doable in the home shop, you could probably even 3D print a codewheel with that slot width. (You can of course make the codewheel any size you want as long as you keep the same line spacing.)
@@AndysMachines Now I managed to program the thing but my keypad shield doesn't show any digits. it gets power and the LCD lights up but no individual digits and it doesn't reboot after programming either. I have an Arduino Uno R3 and a shield that looks identical to yours. Any tips?
Sorry, not sure what's going on there, could the shield be plugged in improperly?
@@AndysMachines I compared all the pins already and also there are gaps between rows of pins that cannot be plugged in in another way. Ich tested the program too with two switches and toggled them for a few minutes. The motor didn't move so I think the programming in general went wrong somehow even though the command prompt told me it had worked. I don't know if programming with atmel studio could change anything.. I could do that at work.
@@AndysMachines Small update: the controller was programmed correctly, I just had to tune the contrast of the keypad shield.