Orient

  • JT
  • JT's Avatar Topic Author
  • Away
  • Administrator
  • Administrator
More
17 Jan 2023 15:02 #262242 by JT
Orient was created by JT
Has anyone successfully implemented spindle orient?

If so do you have notes or and example?

JT

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 15:33 #262244 by spumco
Replied by spumco on topic Orient
JT-

Yes, I've got orient working, but it's fussy and hardware dependent.

My particular config is based on a VFD w/2-pole motor, spindle encoder w/index, and a pneumatic shot-pin to nail the index position.

If your hardware is capable of tightly holding a position (servo or servo-like) orient should be easy-ish.  If not, it may take some aggravating tuning or a helping hand from a brake or other mechanical device to hold position.

Basic arrangement is that there are two PID loops - one for spindle mode, and one for orient mode - and some HAL logic to switch between the two.

Before I swamp you with my non-trivial hal files...what hardware do you have?
The following user(s) said Thank You: JT

Please Log in or Create an account to join the conversation.

  • JT
  • JT's Avatar Topic Author
  • Away
  • Administrator
  • Administrator
More
17 Jan 2023 16:15 - 17 Jan 2023 16:18 #262247 by JT
Replied by JT on topic Orient
I have a velocity servo with encoder feed through.

Tom said this is Andy's diagram but he is having issues trying to make it work and I'm just getting started.

tom-itx.no-ip.biz:81/~webpage/cnc/config...LL_ORIENT/orient.jpg

After reading your reply again the diagram makes more sense to me now.

JT
Last edit: 17 Jan 2023 16:18 by JT.

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 16:51 #262253 by spumco
Replied by spumco on topic Orient
JT - Good to hear the diagram is helping.  I had to have Andy and a few other folks hold my hand a while back while I was struggling.

My spindle hal file is attached - note that there are a few lines commented out.  I haven't cleaned it up yet so ignore those.

If anything isn't clear let me know; there may be hal connections missing from that file that are in my main hal file.

-R
Attachments:

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 18:05 #262257 by JPL
Replied by JPL on topic Orient
This guy going by Talla83 made some very interesting video about this and even provided a full configuration for 5i20 -> 7i33.
See here: www.talla83.de/  under 'LinuxCNC Spindle-Control'.
Video is here:

Configs are here: talla83.de/linuxcnc/config.htm

If only I would have a better understanding of German language...
 
The following user(s) said Thank You: JT

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 21:13 #262271 by tlightus
Replied by tlightus on topic Orient
could you please explain what drives motion.digital-out-07 and what tristate-bit.0. is doing there? I think i understand it but don't know where you're triggering motion.digital-out-07. What i see happening there is the digital pin feeds tristate when a tool change is requested which sets spindle-index-enable. Then the next round orient takes effect. Am i even close? Still reading the rest of it but thanks alot.

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 21:23 #262273 by spumco
Replied by spumco on topic Orient
I knew I should have pasted all my files....

I'll get them up when I get home and we'll dig through everything together.  It'll be a couple hours.

I think PCW (or maybe Andy) tipped me off about tristate when I was having problems getting the spindle index signal to reset low.  I seem to recall the symptom was that orient would work once, and then subsequent attempts would fail (spinning/hunting for an index signal until it timed out) because I couldn't reset the index pin.

If you're impatient, you could probably search under my user name sometime between (appx) last May to September.
The following user(s) said Thank You: JT

Please Log in or Create an account to join the conversation.

More
17 Jan 2023 22:57 #262280 by spumco
Replied by spumco on topic Orient
Relevant files attached.  Note that I don't use orient for anything other than homing the spindle so my drive dogs line up with the ATC forks.  My VFD isn't capable of holding a position.  It just gets close enough for the shot-pin to drop in and hold it.  No way I could reliably command a specific position.
  • 01_PBATC.hal
    • main hal file.  All loadrt & addf are here.
  • 02_atc.hal
    • connections to motion.digital/analog in/out.
  • m27.ngc
    • one of the toolchange files used in my M6 sequence
    • Used for initial homing of the spindle
    • turns spindle-index-enable on & off via motion.digital-out-07 (M64/M65 P7)
    • After that, it rotates the spindle at 250rpm for a bit so orient can re-aquire the index pulse.
  • m23.ngc
    • Another toolchange file
    • Used for all subsequent spindle orientation (takes less time)
    • Does not require the spindle-index-enable dance.
NOTE - If I remember correctly.. I was wrong in my earlier post. The symptom cured by the motion-digital-out-07 => tristate => index-enable fandango was not continuous spinning.  It was the spindle settling at the wrong location during an orient command.

Basically, wherever the spindle was when orient was commanded was interpreted as the 'index' point, and orient would rotate the spindle until it found the false index plus whatever offset I had programmed in INI file.

Both spindle.0.index-enable and pid.s.index-enable need to be reset to false before orient will work  If I don't turn on/off the spindle-index-enable before orienting:
  • Orient commands rotation
  • Shot pin fires (spring-loaded)
  • Shot pin drops in
  • Orient keeps trying to rotate because it's not at the false index
  • Shot pin complains very loudly
  • Orient muscles through with the shot pin & pocket crying
  • Orient errors out because it just got a load applied by the shot pin and can't make it to the finish line in time
  • I cry a little
Keep in mind that this complicated config may not be necessary for a different hardware combo.  If a servo spindle is used it's likely capable of holding position properly.  Even a 'smart' VFD and a 4pole induction motor might be able get close enough for a basic homing routine.
Attachments:
The following user(s) said Thank You: tlightus, JT

Please Log in or Create an account to join the conversation.

More
18 Jan 2023 00:01 - 18 Jan 2023 00:06 #262289 by tlightus
Replied by tlightus on topic Orient
would you mind adding your toolchange.ngc and remap.py to the group?
thanks
Last edit: 18 Jan 2023 00:06 by tlightus.

Please Log in or Create an account to join the conversation.

More
18 Jan 2023 02:35 #262311 by spumco
Replied by spumco on topic Orient
How about I just dump everything on you?

My ATC scheme is a result of me going off the Probe Basic reservation.  The PB simulation is designed to support a geneva wheel mechanism and the various Mxxx .ngc files are used to calculate shortest-path as well as drive the geneva wheel with a dumb AC or DC motor.  It does not use the carousel.comp component - all math & logic is handled in the PB Mxxx files.

My configuration uses a stepper motor driven by carousel.comp in 'counts' mode (to keep track of pockets).  Hence the need for a rather different config than the PB sim.

The toolchange_test.doc is a bunch of notes I was taking trying to untangle the Probe Basic tool change scheme.  Took me a while, but you might find something useful in there.

Remember - it's a work in progress and not in a lock-down state.  There is some lingering junk in the ATC folder where I tested a bunch of changes and haven't deleted all the previous versions of files.  There are also the (more or less) original Probe Basic tool change .ngc files, but the MAIN file is toolchange.ngc.

The comment(s) at the top of the .ngc files should tell you what's being used.  If there aren't a crap-ton of comments in a particular .ngc file, it's a leftover and not in use.

I'm sure you'll have questions, don't hesitate.  I could certainly use help too.

-Ralph
Attachments:
The following user(s) said Thank You: tlightus, JT

Please Log in or Create an account to join the conversation.

Time to create page: 0.108 seconds
Powered by Kunena Forum