Author Topic: CSMIO-ENC Spindle Orientation  (Read 8205 times)

0 Members and 1 Guest are viewing this topic.

Offline LM941

  • Active Member
  • Posts: 12
    • View Profile
CSMIO-ENC Spindle Orientation
« on: January 16, 2016, 07:38:00 PM »
Trying to orient the spindle for tool changes.

CSMIO/IP-A, CSMIO-IO, CSMIO-ENC

Check box in "Align at stop" of csmio plugin is enabled. Spindle encoder is connected to ENC module. RPM and spindle orientation show in monitor.

Machine is Bridgeport VMC 760/22 with Siemens 911 drive control, analog +-10

Anyone know how this function in CSMIO-ENC works? Just found today that M19 exists but not at machine to try or see if it needs macro code.

I can read the position with a macro but the spindle needs to be < 5 rpms to catch 0(zero) degrees reliably.

First post on forum. New to Mach3 and CS-Lab controllers. All the retrofit has gone amazingly smooth and then this silly spindle orientation smacks me.

Thanks for any help..




Sent from my iPhone using Tapatalk

Offline Hood

  • Mach4 Alpha
  • Posts: 25,774
  • Carnoustie, Scotland
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #1 on: January 17, 2016, 05:43:29 AM »
Never tried it on the Chiron which is the machine with the IP-A as I do not need to orient the spindle for tool changes.

I did use it on the wee lathe to stop the spindle at the correct position for the chuck key and it worked well. The wee lathe however had an IP-S.

All I had to do was enter a value in the angle box and enable the option, no macro required.

If I get a chance and more importantly remember I will test it out on the Chiron when I get back to the workshop tomorrow.

Hood

Offline LM941

  • Active Member
  • Posts: 12
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #2 on: January 17, 2016, 12:37:58 PM »
Thanks Hood! I have been reading your posts for the past month and you have helped tremendously with my questions during this project.

The encoder is off a 1:1 pulley with 1024 count. CSMIO was reporting 4 revolutions for 1 actual revolution so I had to set P/Rev to 4096 to sync. Not sure why this encoder has such low resolution unless controls in 1995 couldn't keep up at 6000 rpms?

Before purchasing the ENC module, I had the encoder connected to Channel 3 of CSMIO/IP-A.  The config screen (attached jpg) does not allow any Channel option for ENC-1 encoder port. I can only assume the plugin does it automatically. Besides it not stopping at angle set, there are some other odd things like Mach3 GUI speed controls doing nothing but S codes do.  RPM dro is being updated fine.

One area that might be problematic is the Mach3 [Spindle CW F5] button controls a relay that opens the SimoDrive 611 Spindle control enable signal,  immediately stopping the spindle and disabling (required for tool unclamping).   I am not sure how long CSMIO-ENC needs to orient it and if it is disabled too fast.  I have tried overriding the spindle enable but it didn't seem to resolve it.

http://www.machsupport.com/software/plugins/  - shows ENC in plugin list but the link is no good.  I hope this isn't me just missing a plugin. I have found nothing related to a separate ENC plugin on cs-lab website.

Offline Hood

  • Mach4 Alpha
  • Posts: 25,774
  • Carnoustie, Scotland
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #3 on: January 17, 2016, 01:34:41 PM »
Ok, just wondering if the demo version of Mach may have something to do with it.

Yes, encoder pulses per rev are 4x the encoder line count and yes, that is the reason machines of that vintage had low count encoders.

Enc1 input is dedicated to the spindle encoder, the other ports are dedicated to DROs so you can use them for other purposes, for example I use the second channel on the Enc module for a glass scale on my tool height setter.

You might have the problem with the disable set up that way, in fact if I understand the way it is working then I am certain it wont work.
The CSMIO needs to slow the spindle to a stop and then find the Index, occasionally I saw my spindle do almost a full revolution after it had basically stopped.

Hood

Offline LM941

  • Active Member
  • Posts: 12
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #4 on: January 17, 2016, 02:12:25 PM »
That's funny you noticed the Demo in the title. I hadn't.  We bought the Mach3 License from CS-Labs and I went through the install of the plugin without paying attention to the Mach3 install. Had downloaded previous to play with and never got any nag screen. Definitely need to clear that up and be sure it is not causing any issue.  

I am am using brains to control that spindle enable output so maybe I can use some delay.  Brains are another subject of head scratching.  CS-Labs documentation on the ModBus integration is sparse.  I tried using some brain terminators to control a CSMIO output via ModBus but gave up and just configured the output through Mach3 ports and pins.

Heading to try some spindle disable delays and will let you know.  Thanks again.

Offline Hood

  • Mach4 Alpha
  • Posts: 25,774
  • Carnoustie, Scotland
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #5 on: January 17, 2016, 02:20:18 PM »
I prefer the macropump to Brains although if you have a lot of stuff in there Brains can be better as you can have many small brains where you can only have one macropump.

Hood

Offline Hood

  • Mach4 Alpha
  • Posts: 25,774
  • Carnoustie, Scotland
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #6 on: January 17, 2016, 02:21:19 PM »
Oh and as far as the licence, you should have a file called Mach1Lic.dat, make sure that is in the main Mach3 directory. If it came zipped then you will need to unzip it.
Hood

Offline LM941

  • Active Member
  • Posts: 12
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #7 on: January 18, 2016, 08:57:17 AM »
Hood, is your machine that aligns spindle at stop using the DAC axis output or the other analog outputs?

Offline Hood

  • Mach4 Alpha
  • Posts: 25,774
  • Carnoustie, Scotland
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #8 on: January 18, 2016, 02:22:33 PM »
The lathe had the IP-S on it and the spindle was a Step/Dir servo.
Originally the servo drive used the analogue  0-10v output because at the time there was no way of using a Step/Dir spindle, however I didn't have or try the orientation when it was set up that way.

Today I tried the orientation on the Chiron which uses the IP-A controller but it didn't work very well, that may be due to the interpolation and division I have set up in the servo drive for the encoder outputs.
 I ran out of time or I would have had a look to see what I have set in the servo drive.

Will try and get a look in the next few days.

Hood

Offline LM941

  • Active Member
  • Posts: 12
    • View Profile
Re: CSMIO-ENC Spindle Orientation
« Reply #9 on: January 18, 2016, 03:40:38 PM »
Thanks,  I spent more time today on the spindle and have some more observations and discoveries.  Between Mach3 and CSMIO plugin the settings seem infinite. The CSMIO/IP-A manual did a pretty good job with help tuning the PID for the XYZ axis but not much on spindle PID tuning.  The screen shots in manual don't match plugin screens. Calibrating the spindle to get RPMs matching S command was a lot of trial and error. I played with the Mach3 Calibrate spindle function and then read here many saying it doesn't work. It shows PID of P=0.25, I=1, D=0.3. I can't set the CSMIO spindle PID, P less than 5.  No idea what PID to even start with in CSMIO spindle PID settings.

Attached are the best settings I got so far for Spindle to work ok as far as CW, CCW and RPM control. Once I make the PID Regulator - Open Loop in CSMIO plugin, the Align at stop option is disabled.

I made an M19 (spindle orient) macro and it kinda works if I run spindle at S2 and use GetInput (84) to look for angle Zero (where my tool changer wants it). It does not seem to be able to read the encoder input fast enough to be on target all the time. Wish they had a command to OrientSpindle(x) where x was angle.

Frustrating part is I think the Siemens 611 spindle drive Simodrive has the ability to stop at oriented angle but I thought the ENC would be easier  ::)

https://cache.industry.siemens.com/dl/files/160/98209160/att_2547/v1/IAA_1000_en.pdf