584,798 active members*
4,408 visitors online*
Register for free
Login
Results 1 to 8 of 8
  1. #1
    Join Date
    Nov 2017
    Posts
    591

    threading in mill profile

    im setting up a mill turn configuration that uses a horizontal servo driven secondary spindle that doubles as a 4th axis. the horizontal spindle is switched between a spindle and A axis using a swap axis macro. it uses gang turning tools next to the milling head to do both turning and milling operations in the same program using only the mach3 mill profile. ive managed to hack up a fanuc turning post to do everything i want from fusion 360 cam without using an x-z swap on the machine to handle turning code. instead i did the swap in the post, outputting x for z and z for x. arcs no longer work properly, but i just forced it to not use arcs by reducing maximum arc to very small number. everything is working fine except for singe point threading on the horizontal spindle. I already know how to make it happen using a synchronized A, X move. for example, A3600 x10 will do 10 threads at 1mm pitch. its just kind of time consuming to manually write it out for multiple depths, zeroing A at beginning of each pass, etc. It would be nice if i could get a threading cycle from fusion 360 to work properly and not need to manually write it. Or at least a shorter version of writing it. Is there any way to make this work in the mill profile like it does in the lathe profile? Or am i stuck just writing it with the spindle as an axis? If i am stuck doing it as A axis, is there a convenient way to write it? Currently when i cam the threads in fusion, its outputting G32 for threading and it almost works. this is an example of what it gives me for a 3 pass 1mm pitch:

    N10 G98 G18
    N11 G21
    N12 G50 S2800
    N13 G53 Z0.


    (THREAD1)
    N14 T60 M6
    N15 G54
    N16 G99
    N17 G97 S500 M3
    N18 G0 Z16.35 X-80.
    N19 G0 X-75.
    N20 Z6.183
    N21 G32 X-0.167 F1.
    N22 Z6.35 X0. F1.
    N23 G0 Z16.35
    N24 X-75.
    N25 Z6.017
    N26 G32 X-0.333 F1.
    N27 Z6.35 X0. F1.
    N28 G0 Z16.35
    N29 X-75.
    N30 Z5.85
    N31 G32 X-0.5 F1.
    N32 Z6.35 X0. F1.
    N33 G0 Z16.35
    N34 X-80.


    N35 G53 Z0. X0.
    N36 M30
    %

    remember that my x and z is swapped in the post, so x moves are moving along the axis of the horizontal spindle and z is the depth of the thread, also x moves positive toward the chuck. my post is also modified to output in radius mode instead of diameter. Each pass does what its supposed to, it moves in feed per rev as it should, gives a 1mm pitch cut, but the multiple passes dont line up. Is it simply not capable of lining up the multiple passes since its being done in mill profile? the other possibility is the fact that im not giving it an encoder pulse. since my horizontal spindle is a step/dir driven servo, mach3 should always know its exact position without needing the pulse input, but maybe it still wants it to make this work? my dyn4 servo drive is capable of sending an encoder pulse to mach3 if that will help, but it needs a specific cable and more wiring to do it. Ill do it if its likely to fix the issue, but i dont want to bother if its not gonna help. Is this type of cycle just not gonna work in the mill profile?

  2. #2
    Join Date
    Dec 2013
    Posts
    5717

    Re: threading in mill profile

    I think Mach3 requires an index pulse from the spindle, at least one per revolution to time the passes.
    Jim Dawson
    Sandy, Oregon, USA

  3. #3
    Join Date
    Nov 2017
    Posts
    591
    Quote Originally Posted by Jim Dawson View Post
    I think Mach3 requires an index pulse from the spindle, at least one per revolution to time the passes.
    Technically with a step/dir spindle, it should already have all the data it needs since it's constantly commanding the spindle to an exact position, but it might not access that data for this purpose and still need the index pulse. What I'm more curious about is if the mill profile will even be capable of threading cycles once it does have the pulse. Might have to wire it up to find out. Was hoping someone knew so it would save me the trouble of wiring it up if it's not gonna work anyway.

  4. #4
    Join Date
    Nov 2017
    Posts
    591

    Re: threading in mill profile

    Update to this, I wired up the index pulse from the dyn4 drive and mach3 is properly reading and displaying rpm. As i suspected it didn't solve the issue. It seems that the mill profile just doesn't respond to g32 or g76 like the turn profile does. Everything moves as it should. it moves in feed per rev and gives correct thread spacing but the multiple passes don't line up.

    So the question is, how can i get around this? I can modify the post to output whatever i want rather than g32. I'm guessing g32 is basically supposed to stop and wait for a pulse, then continue at feedrate when it receives a pulse. Is there something I can put in place of g32 that will accomplish this? Like a macro that tells mach3 to wait for a pulse, then continue at feedrate? Would an M code work when put in place of the g32 and still using the rest of the line? Or do M codes need to be on their own line? The existing line of code works fine, it's just not waiting for a pulse before starting to feed. I would really like to make this work so it's output from fusion cam and doesn't need further modification to the code after posted. Any ideas?

  5. #5
    Join Date
    Nov 2017
    Posts
    591

    Re: threading in mill profile

    Ok, turns out g32 works in mill profile. Had no idea I needed to go into spindle setup and check the box "use spindle feedback for synchronization". It now pauses to wait for the pulse and passes are lining up. Very close now, but still some slightly odd behavior. At the end of a thread pass it waits and makes a few revs before retracting. Nothing in the code telling it to do that so I'm not sure why. It cuts a groove all the way around at the end. I also had another odd glitch. Every once in a while it will pause before starting a thread pass, then just rapid right to the end of the pass dragging the thread tool through the stock. Not sure what's causing that either but I hope I figure it out. So close to getting threads straight from fusion 360.

  6. #6
    Join Date
    Dec 2013
    Posts
    5717

    Re: threading in mill profile

    In Fusion try checking Passes > Fade Thread End. This may keep it from dwelling at the end.

    Not sure what is going on with the rapid problem, but it sounds like you are close.
    Jim Dawson
    Sandy, Oregon, USA

  7. #7
    Join Date
    Nov 2017
    Posts
    591
    Quote Originally Posted by Jim Dawson View Post
    In Fusion try checking Passes > Fade Thread End. This may keep it from dwelling at the end.

    Not sure what is going on with the rapid problem, but it sounds like you are close.
    I figured out the random rapid problem. At least what it's related to. My mill turn setup is a bit tricky since I'm handing spindle control back and forth from vertical 2.2kw milling spindle to horizontal turning servo spindle. The vertical vfd spindle is controlled by a plugin which works independently from the settings i put in mach3 motor tuning for the servo spindle. This allows everything to work the way it needs to when switching from milling to turning even though one is step/dir and one isnt. One drawback to this is that when I swap to the turning spindle, the vertical spindle still runs at the same time with spindle commands. Since the horizontal spindle is never commanded higher than 3k, the vertical spindle just runs at its minimum rpm of 7200 while the horizontal spindle runs. It's not really a problem, but the plugin that runs it occasionally interacts with the rpm readout that the index pulse from the horizontal servo is giving me. For example if I'm running a threading cycle at 500rpm with the horizontal spindle, the rpm readout will show 500 as it should, but with an occasional little flash of 7200 which the vertical spindle is running at. I think the rapid move is when the g32 cycle thinks it suddenly needs to feed fast enough to thread at 7200rpm, which would basically be about rapid speed. I found that when I disable the plugin for the vertical spindle, the occasional rapid through the threads no longer happens. Now here's the weird part and how I have it solved currently, when i go into the plugin configuration and turn off the plugin, it doesn't actually disable the vertical spindle until i restart mach3, BUT, when I disable the plugin and don't restart mach3, the vertical spindle remains functional but somehow the plugin stops interacting with the rpm readout and no longer gives the occasional blip of 7200rpm and everything works.
    So long story short, when I power up the machine i just need to hit the checkbox to disable the plugin, and before I shut the machine down when I'm done working, I need to re enable the check box so it doesn't actually fully disable the spindle the next time i start up. Its a weird fix and doesn't make alot of sense, but it's working and the results are very consistent. I've tested it extensively. With the plugin fully enabled, it does the rapid through threads at least once every 3 or 4 passes. With the plugin "half" disabled (check box off, but mach3 not restarted and vertical spindle still functioning), it never does the rapid through threads. In this state I ran a 10 pass threading cycle probably 30 times just to make sure it wasn't a weird coincidence.
    I would like to eventually find a better fix that doesn't involve needing to hit that checkbox at every startup and shut down, but for now it's working.
    As for the dwell at the end of threading pass before retract, i haven't figured that out yet. Fade thread end doesn't help, actually makes it worse since it spreads out the full groove at the end. Really it's not a big deal that it's giving a full groove at the end. In a lot of cases I'll be doing a thread relief at the end anyway, so that dwell can happen in the relief. Ill keep digging into that and hopefully figure it out, but it's manageable for now. I did notice when spindle sync feedback is disabled and thread cycle runs without lining up passes, the dwell goes away, so its definitely somehow related to the index pulse and synchronizing. Almost like the g32 is not only waiting for a pulse on entry, but also waiting for a pulse on exit, or something like that. I'll keep playing with it. Now that threading synchronization is working in general, I can also try a couple other cycle types to see if it behaves differently.

    For now I'm far enough along that i think I'll take a break from the programming headaches and finish up milling the gang tooling attachments. Just about ready to run some full on mill turn parts. Very exciting!

  8. #8
    Join Date
    Jun 2010
    Posts
    4252

    Re: threading in mill profile

    I do threading on the lathe under Mach3Turn, and I use a single point thread milling cutter on Mach3Mill. Both work fine. I would not try mixing them, like trying to use G32 in Mill. I doubt the code for that has been properly tested.

    I don't use any CAM; I hand code the lot, and it runs very well. Mill does helical movements very nicely. Um - single-point thread mills are not cheap, but careful calibration works fine. I have gone from M3 to M24 just fine. I have not yet tried my M2 thread mill: it is a bit tiny!

    On the lathe I use gang tooling, up to 4 tools in one header. That too goes well. It does take some effort/time to set up the Tool Table, but the TT can be saved.

    Cheers
    Roger

Similar Threads

  1. Mill Threading
    By ajclay in forum Mach Mill
    Replies: 3
    Last Post: 05-25-2011, 02:39 AM
  2. How to profile a pocket with an end mill?
    By jamie1 in forum Mastercam
    Replies: 12
    Last Post: 10-27-2010, 01:48 PM
  3. Help with threading on a CNC mill
    By shorety in forum MetalWork Discussion
    Replies: 9
    Last Post: 06-14-2009, 03:15 AM
  4. Beginner full profile threading question
    By SRT Mike in forum MetalWork Discussion
    Replies: 0
    Last Post: 07-23-2008, 05:40 AM
  5. ID Mold Threading profile
    By Wiseco in forum G-Code Programing
    Replies: 2
    Last Post: 07-15-2005, 09:41 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •