Hello Guest it is November 15, 2019, 03:41:14 PM

Author Topic: Mach4 newbie here. I need some help  (Read 4123 times)

0 Members and 1 Guest are viewing this topic.

Re: Mach4 newbie here. I need some help
« Reply #30 on: November 23, 2017, 04:42:00 PM »
Note: I just installed Mach4 to another computer to take the screenshot. It's not from the computer that I use for the Lathe.
Re: Mach4 newbie here. I need some help
« Reply #31 on: November 23, 2017, 05:32:51 PM »
Hi,
I believe they are one in the same. The index pulse is converted to True RPM. If the feedback ratio on the spindle
range page is equal to one the the True RPM is the same as the Index RPM.

If you had two pulses per rev of the spindle you would set the feed back ratio to 2 (0.5??) and the index RPM would
be correctly converted to spindle RPM.

Craig
My wife left with my best friend...
     and I miss him!
Mach4 newbie here. I need some help
« Reply #32 on: November 25, 2017, 12:21:08 PM »
I think I'm doing this all wrong. The in the video has a similar setup. I'll try the same.

https://youtu.be/7g_4gjZMA3g

Sent from my MI 5s Plus using Tapatalk
Re: Mach4 newbie here. I need some help
« Reply #33 on: November 25, 2017, 02:46:57 PM »
Hi Azalin,
I think we often spend too much time worrying about spindle speed. Quite a few of the jobs I do on my mill are engraving type jobs, PCB routing particularly.
All I require is that the spindle starts, go to max RPM and stay that way until the job is done. I don't need/want it to go backwards, I don't care what the true
RPM is, I mean I can tell at a glance whether the spindle is going OK.

May I suggest rather than attempting to set your machine up so that you have fine speed control and true speed feedback with all the complication and confusion
of software setup and hardware compatibility that you settle for a simpler solution. When your comfortable with that then start extending your control and then
only to the extent required to do the machining you require. Do you actually require precise indexing and speed control for rigid tapping UNLESS you are doing
rigid tapping?

The video you linked is a very simple and common set up. It defines two outputs: one for ON/OFF control and the other as a PWM signal that results in a 0-10V
analogue signal to your VFD/spindle driver. It may be, like my engraving job, that you don't need the PWM speed control, you might have a potentiometer and
knob that you can lean over and tweak to do the job at hand. If you need to be able to go in reverse you will need more outputs.

You could use as few as two: one for FWD and the other as REV and with neither output active STOP. Or you could have three outputs: one for ON/OFF,
and the other two for FWD and REV. Use whatever seems simplest to adapt to the input circuit of your VFD/driver.

Likewise most VFD/drivers accept an analogue voltage and most BoBs output an analogue voltage usually from a nominated pin so connect one to the other.

At this stage who cares about spindle feedback? You will know immediately if the spindle is doing what its supposed to or close to it. Even if you do have an index
pulse setup and true RPM displayed without some sort of closed control loop you can't adjust the spindle speed anyway. And before you ask Mach is not a closed loop
controller. You will no doubt have seen posts about it and using some clever coding and/or hardware you can induce Mach to close a control loop but its performance
is pretty lethargic. There are external motion controllers that have closed loop control capacity, often called PID, but they cost extra, a lot extra as a rule and it
begs the question 'how precise/detailed/accurate/dynamic do I require my spindle speed control to do my machining?'

If you find that you need really precise indexing and speed control for rigid tapping say the buy yourself a decent AC servo and drive. You can shag around with
feedback controllers and encoders until 'the cows come home' and still not match the control offered by a matched AC servo and drive. All that is required with such
a matched pair is a Step/Direction signal pair....no encoder feedback, no PID tuning, no headaches!

Keep your spindle speed control solution as simple and cheap as you can...save your time and dollars for other things!

Craig

 
My wife left with my best friend...
     and I miss him!
Re: Mach4 newbie here. I need some help
« Reply #34 on: November 25, 2017, 04:01:26 PM »
Hi Craig,

The machine I am trying to setup is a lathe. I need spindle indexing for threading. I have to get it done.

Best,
Suat
Re: Mach4 newbie here. I need some help
« Reply #35 on: November 25, 2017, 04:18:55 PM »
Hi,
OK, you require indexing....start by getting the spindle to work! If you don't have control of the spindle then indexing is pointless.

Craig
My wife left with my best friend...
     and I miss him!
Re: Mach4 newbie here. I need some help
« Reply #36 on: November 25, 2017, 04:33:56 PM »
Hi,
my comment about the suitability of an AC servo as a spindle motor applies equally to a lathe spindle.

Mach requires one pulse per rev, an index, to calculate and synchronise a thread. Mach assumes that the speed is constant even when the tool engages the
material and starts cutting. We all know that is never actually the case, the spindle always slows a little. Even with closed loop control a feedback of one pulse
per rev is not enough for a controller to maintain spindle speed accurately enough for threading.

Most modern AC servos have encoders of 10,000 count per rev and feedback/control loops in the kHz range. The control bandwidth is such that it can maintain
its speed accurately many hundreds of times per revolution which beats the hell out of any other motor with a simple index pulse.

Craig
My wife left with my best friend...
     and I miss him!

Offline Tweakie.CNC

*
  • *
  •  7,997 7,997
  • Super Kitty
    • View Profile
    • Tweakie.CNC
Re: Mach4 newbie here. I need some help
« Reply #37 on: November 27, 2017, 02:06:19 AM »
Quote
Mach requires one pulse per rev, an index, to calculate and synchronise a thread. Mach assumes that the speed is constant even when the tool engages the
material and starts cutting. We all know that is never actually the case, the spindle always slows a little. Even with closed loop control a feedback of one pulse
per rev is not enough for a controller to maintain spindle speed accurately enough for threading.

Sorry Craig but this is not quite true - there are many lathe users threading this way.

Tweakie.
Success consists of going from failure to failure without loss of enthusiasm.  Winston Churchill.
Re: Mach4 newbie here. I need some help
« Reply #38 on: November 27, 2017, 03:44:07 AM »
Guys, I get the spindle working. I mean, M3 and M5 is working. I also get the green light when the index sensor is aligned with the slot on the disc. However, I don't have any index reading. When I hit the CW button in Mach4 the spindle starts rotating but the real spindle speed always zero.



- The index sensor is connected to PIN 15. I did the Darwin setup. Also mapped index to index in Mach inputs screen.
- I set the base PWM frequency in Darwin diagnostics screen to 300.


I wonder why there is no complete documentation for the Darwin plugin.
Re: Mach4 newbie here. I need some help
« Reply #39 on: November 27, 2017, 03:54:49 AM »
And some screenshots of the setup. Please let me know if more info needed.







I have played with the index debounce but didn't change anything. I used to use 20 in Mach3.
« Last Edit: November 27, 2017, 03:58:20 AM by Azalin »