Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: mike^3 on November 14, 2015, 10:46:25 AM

Title: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 10:46:25 AM
Hello everyone!

I love this forum!

I am almost complete with my CHNC4 to mach 3 conversion, however I am having an issue, the spindle speed is not trying to correct to the commanded spindle speed position.

Here is a quick video.

https://www.youtube.com/watch?v=FjkSUMz8I6o

Any help guys?

I have an Ethernet Smooth Stepper with a c23 board. I can change the spindle speed manual with the speed box, but it will not try to correct to the commanded speed.

THANK YOU ALL SO MUCH!
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 14, 2015, 11:14:38 AM
does this help at all?

http://www.warp9td.com/index.php/faq/f-a-q-mach3#Spindle

(sorry not set up a spindle before)

... it is specifically for the ESS ... and there are settings on the SS config page too

Rob
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 11:16:54 AM
Thank you for the link, I tried that and that but it still does not attempt to correct the speed for commanded... :|

Thanks tho! :)
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 14, 2015, 11:22:06 AM
The last item ... Does this not provide a calibration for the DRO
Finally go to Mach3's Menu -> Config -> Spindle Pulleys

 Choose a pulley
Choose a min and max RPM so that the spindle feedback can calculate the correct RPM for display
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 11:25:47 AM
I did choose a pulley = 1 and then i put 0 min speed and 6000 max speed, still doesnt work :(
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 14, 2015, 12:01:28 PM
What happens if you change the ratio to 1.5?
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 12:02:38 PM
it will adjust the read speed but it will still not fight to keep the spindle at commanded position, Im gonna try a tip from Tweakie.cnc then check back with ya :)
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Tweakie.CNC on November 14, 2015, 12:13:46 PM
Quote
Im gonna try a tip from Tweakie.cnc then check back with ya

 ;D

Tweakie.
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 14, 2015, 07:43:25 PM
HIYA Mikey , First closed loop NEVER work worth a hoot even with teh LPT and I dought it even works at all with a ESS. What you see is a linear config error. The voltage output is NOT linear with the RPM called. THAT is a function of teh ESS to control that probably a ESS setup problem with teh spindle control.

Normally MACh3 does NOT attempt to correct ANY spindle speed. You just have what the spindle is doing and that is it. IF it boggs down it just boggs down UNLESS your spindle speed controller itself can do Closed loop control and MOST don't unless it is a SERVO spindle.

IF you were useing an LPT I could show you how to correct the linearity problem BUT I don't know squat about the ESS's spindle output control.

BUT there is probably a manual out there somewhere that may have the answer ????

(;-) TP

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 09:47:19 PM
That's weird because the lathe we worked on tp did work, but didn't thread lol.
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 14, 2015, 09:47:45 PM
So it's still not workint, any ideas guys? ;)
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 12:41:05 PM
Mike was the OTHER lathe using the LPT or the ESS.  With teh ESS the spindle stup is ALL done from teh ESS side NOT from Mach3.  IF Greg never setup closed loop control then it will NEVER happen.

are you confusing teh OpenLoop Control with CSS ???

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 12:48:04 PM
Well it's funny that you mention that. Cuz I noticed that the first pass would be at 45 rpm, second is like 250 rpm and the final pass is 500 ish rpm.

Yes the other lathe was lpt, not ess.

Will changing to mach4 help these issues? Or maybe a different controller I'm thinking?

I was thinking the csmio or hi con if the ess can't do the spindle right. Maybe kflop?

I really need the commanded spindle to match and try to keep the speed, especially for heavy cuts.

Any thoughts?

Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 02:59:45 PM
The LPT version and the ESS version are 2 different CATS. 

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 03:01:10 PM
So do you think the issue is the ess? Or mach 3?

Can I upgrade to mach4 easily?
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 03:42:21 PM
It would have to be a ESS issue as IT is what actually controls the spindle . You need to speak with Greg over at Warp 9 about this issue.

EVEN IF you could get Mach4Turn to work the ESS still controls the spindle (;-)



(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 15, 2015, 03:50:44 PM
There is a long running topic on threading which I do not believe has ever been resolved.

It is not a mach3 issue.

Mach4 will not bring any of the more complex features yet from the looks of things... My advice if you are in an industrial environment and time is money stick with machmach 3 for the moment given way more people know about it and asking a question will bring 10 armchair experts (me one of them) and three Yoda's.

Cismo has a threading module but you need the controller first have a look at their site.
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 15, 2015, 03:51:31 PM
The threading will probably solve any synchronisation issues....
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 04:01:16 PM
Thanks guys, so Robert, I have a csmio ipa I have worked wity, haven't finished that project yet lol.

I was thinking of getting a hicon motion controller, or dspmc, any info on this control?

I'll probably ditch the ess for the lathe then...I spent so much time lol
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: robertspark on November 15, 2015, 04:23:29 PM
Sorry, I have an ESS unfortunately (for my sins), I looked at hicon (but it was a little out of my hobby range)... I am also more into x/Y tables than lathes.

Probably should have gone cismo at times... Just adding all the modules can be expensive (I'm a hobby tinkerer).

I'd suggest you get a login and have a look at the warp9 forum as the lathe threading thread is fairly high up on the list (1st or second page).

There is also kflop (just another site to check)

Not sure if pdmx can do what you want Steve is quite active on here.

Rob
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 04:41:34 PM
Thanks rob, I just need something that is reliable lol, I have a csmio yet I have little work with it so I am unsure of its abilities. I hooked up the csmio and it runs the drives great, but other than that...haven't done much...
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 05:53:21 PM
Mikey, You need to call Brian @ artsoft and see if he can help you setup Mach4 for TURN on that machine. You already have all teh hardware in place just need the Mach4 setup.

THAT would be a great project for everyone to watch unfold.

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 06:18:05 PM
The ESS can thread very well, there are issues with step/dir spindle but they are minimal and nothing to do with your issue.
I think you said you are using Step/Dir for the spindle control?

Anyway if you are then I would think the ESS is not the problem and more likely the C23 board is not outputting a linear voltage in relation to the steps it is getting fed from the ESS.
Easy way to check if you have a scope, just compare the pulses from the ESS at several speeds and see if they correspond, for example see if the pulses at 1/2 speed are double that at 1/4 commanded speed.
One thing that I would change is lower the pulse width for the spindle, try 2.
Dont know what you have set for steps per unit and accel, maybe there is a magic number required for the C23 board, I know there was for Peter Homanns board.


CSMIO will thread exceptionally well as long as you do not mind having a groove at the end of the thread, this is due to a slow pull out while the CSMIO waits for Mach to tell it to move. That seems to be an issue with Mach3 when using full encoder feedback for threading, the Galil suffered from it as well although I understand Ken found a way round it with the Galil.

I have hoped for a long time that CS-Lab would produce a macro for lathe threading, similar to their rigid tapping macro. As of yet they have not done so, maybe one day they will as to me Mach4 is still years away from doing what Mach3 can do, I could be wrong on that however as I am no longer keeping an eye/interest on/in Mach4.

Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 06:32:22 PM
Thanks tp, would you happen to have a number for brian? I'd love to show everyone my work, I have been making lots of videos of my progress from the first thing I did to it.

Thanks hood, I would need 5o get the csmio ips then, I still have my threading module from the ipa, cuz the ipa has it built in..

I really would like to keep the ess and my setup. Perhaps going to mach4 would be ideal yet I just got the tool changer and all that to work, and from what I understand, programming is completely different in mach4 than mach3.

I posted a question on the warp 9 forum, same prob, but no responses yet.

What I will do is Uninstaller and delete everything, do a fresh install and copy over my macros and screen set with xml and see if that would help.

I will also check with my oscope but I am unsure as to where to test the pulses.

I could just make s chart from 100 rpm to 6000 rpm and make a curve graph to set my spindle speeds lol
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 06:45:56 PM
So you are using Step/Dir for spindle control?

You would just probe the pin on the ESS that you have set to output the Step pulse.

Did you get any values from CNC4PC to input for Vel and Accel in the spindles motor tuning? As I said I used a board from Peter Homann (very briefly) on one project and when the correct numbers were used in Motor tuning the voltage was linear throughout the range. Whether the C23 is as good at keeping the voltage linear throughout the range I have no idea as I have never used any of their boards.

The IP-A still requires an Enc module for threading, technically it shouldn't as it has encoder feedback but CS-Lab have not allowed this to be used, I think for simplicity in having IP-S and IP-A plugins similar.

Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 06:56:29 PM
One other thing to check is the voltage output from the C23, it may indeed be linear and it may be your VFD that does not do the control well.
Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 07:24:17 PM
Thanks hood, I'll check the voltage across the range from the output of the c23 board, I did check briefly and it was 10v at 6000rpm and 5v at 3000rpm...

The values from the motor tuning are 1000 for steps and 60 for velocity. I say go 6000 rpm, and I get 10v out of the card, 3000 rpm I get 5v, etc. So I believe it's linear coming out of the card.

I'll check again, and you may be right about the vfd....it may not be handling the voltage correctly.


However does the ess not account for true speed and actual speed...and correct for it? I find this hard to believe that it is not available.

Also I am using step and dir for the output in the ess configuration option. Would you think that getting a pwm to 0-10v card would help? However if the ess is not correcting for true spindle speed than I doubt it...
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 07:33:36 PM
If you are indeed getting a linear voltage out then it is neither the ESS or  the C23 but points towards your VFD. There may be settings in the VFD you could alter to make it more linear but likely it is just not that great.
No there is nothing in the ESS that will correct the RPM, it has no true feedback and even the PP doesn't do that well if at all.

Using PWM would make no difference, if you are saying the output voltage is linear then the VFD is the issue.

Best you can do is like you suggested earlier, make a note of RPM achieved from different commands and command the speed required for the speed desired.
You could probably, if you were so inclined, do it all within the SpindleSpeed.m1s macro, so that when you commanded 500 rpm it would actually output a command of say 600 to give you the 500.

Just for your information, the commanded spindle speed does not need to correspond to the true spindle speed when threading. As long as the feedback to Mach is accurate, ie the rpm the spindle is actually doing is also the RPM Mach shows, then your threading should be ok.



Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 07:40:47 PM
Mmm very good point... so that solves the that.

So what about the threading g76 command and how for some reason it does each pass at different rpm?
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 08:02:42 PM
Uncheck spindle speed averaging and then run a thread and see if the RPM stays constant in the true DRO. If it does then I am not sure, if it fluctuates then it could be your VFD is doing some form of compensating, especially if the RPM slows initially then corrects as the pass progresses.
If that is happening then it is likely your problem that the VFD is trying to compensate, the ESS tries to compensate and both fight each other.

Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 08:03:30 PM
How would I change the speed file? Any examples?
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 08:10:45 PM
Good point, I'll u check the averaging,..
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 08:18:30 PM
open the spindlespeed.m1s macro for the profile you are using and edit the script.
If you will only be using a certain range of RPM's then it will be easy enough.
For example  something like

If  GetRPM() = 100 then
SetSpinSpeed( 150)
End If

If  GetRPM() = 150 then
SetSpinSpeed( 200)
End If


etc etc

Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 08:34:28 PM
Thanks I will try it
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 08:34:48 PM
Something like this should work if your command will not be exact but rather it would be within a range.

If  GetRPM()  >100  And GetRPM() <150 Then
rpm = 150
End If

If  GetRPM()  >149  And GetRPM() <200 Then
rpm =  250
End If

If  GetRPM()  >199  And GetRPM() <300 Then
rpm = 300
End If  

SetSpinSpeed( rpm)  

Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 08:34:54 PM
IF indeed mach3 is still controlling  teh spindle which I don't think it does then Art wrote an article describing exactly how to get teh Output linear. He wrote it many years agao AND it worked great. I could get teh RPM +/- 2-3 rpm across teh entire range of RPM with a Step/dir spindle controller.

I see if I can find it and post it again. It is probably on this site allready. Just have to look.

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 15, 2015, 08:37:17 PM
Here is teh link to Arts article on calibrating a step/dir spindle.

http://www.machsupport.com/forum/index.php/topic,18580.0.html
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: Hood on November 15, 2015, 08:37:25 PM
Just looked at the first example I gave, likely it would not work as it would likely progress through the macro and set the spindle speed higher each time.

You would need to do it like the second example, ie only have one line that actually sets the commanded speed, that line being the
SetSpinSpeed(rpm)

Hood
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 08:38:28 PM
Thanks hood I'll try that as well.

Thanks tp! That article would be great if we can find it ;)
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 15, 2015, 08:39:12 PM
Thanks tp and hood I'll try both and get back with ya guys ;)
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: BR549 on November 17, 2015, 10:24:46 AM
Hey Mikey, Have you gotten anywhere with this so far ??

(;-) TP
Title: Re: Spindle speed not correcting spindle speed with ESS and C23 board
Post by: mike^3 on November 17, 2015, 10:49:06 AM
I unchecked the spindle speed averaging and it works without modifying the speed per pass which is good, still doesn't account for speed yet. I haven't adjusted the speed file however I will be changing the pulley on the motor, I have like a 12 inch pulley on it, I'm going to put a 4 inch on so I have more torque and speed response. It's very slow to speed up and down without tripping the drive... lol