carousel.comp - jog-FWD still an issue

More
4 years 3 months ago #247578 by spumco
(I figured I'd start a new thread so it doesn't get totally buried in the ATC build thread)

This one's for Andy...

If you recall in the other thread, I don't think the jog-FWD was resolved in carousel.comp counts mode.

carousel last testing

I've pulled the latest carousel.comp from github
I'm triggering carousel from M-codes, not directly from halshow (M64 Pn / M65 Pn)
I've tried changing the width from 2 up to 500
Changed align-dc and fwd/rev-dc speeds up and down
I've reversed my stepper direction - problem is still there, only in the other direction (still FWD)

Every permutation results in jog-FWD moving to the next pocket and then backing up to the original (starting) pocket.

jog-REV - carousel reaches the destination pin sensor, goes past it, and does the slow search in reverse to the destination pin (desired)

jog-FWD - carousel reaches the destination pin sensor, and immediately reverses & slow searches back to the origin pin (not desired)

Any chance you can take another look at the jog-FWD programming?

thx,
R

 

Please Log in to join the conversation.

More
4 years 3 months ago #247920 by andypugh
I wish there was a way to tag a message for attention.
I will try to remember to get back to this.

Please Log in to join the conversation.

More
4 years 3 months ago #247933 by spumco
Thanks.  And no rush, of course.

A temporary workaround is to simply turn off the slow-search function and strictly use counts without the pin feedback.

Please Log in to join the conversation.

More
4 years 3 months ago #248150 by spumco
Andy,

While you're thinking about carousel... I'm trying to do some .ngc logic, and I'd like to read the status of carousel prameter carousel.0.homed.

Just discovered I can't connect a parameter to a signal in hal... Was hoping to link it to motion.digital-in-n so I could poll it with an M66.

Is there a way to read the homed status in an .ngc file? Or can you create a new carousel.0.is-homed bit out pin?

For the moment I can write a persistent numbered parameter after homing, and clear it with a shutdown.hal, but that seems a roundabout way.

Thx,
R

EDIT I can't even figure out how to call a macro at system shutdown - shutdown.hal won't do it.  Kinda stumped.

EDIT 2 - Ok, RTFM.  RS274NGC_STARTUP_CODE + an M-code to set a "homed" parameter to 0 at startup.

Still would be nice to have a carousel homed pin.

Please Log in to join the conversation.

More
4 years 3 months ago #248235 by andypugh
You could read the parameter in a custom M-code, but that's a bit silly.

Just edit carousel.comp to make homed a pin not a parameter and recompile it.

(I will make the same change in the source tree, but that will take some time to filter through

Please Log in to join the conversation.

More
4 years 3 months ago #248262 by spumco
Code:
Just edit carousel.comp to make homed a pin not a parameter and recompile it.

I'm reading the HAL component generator manual page, but 'make a homed pin not a parameter' is a bit Greek to me at this stage.

My startup M-code workaround seems to be accomplishing what I need right now, but I don't think it's going to work in some e-stop or other odd events as it relies on a clean shutdown and restart of LCNC to reset the numbered parameter I'm using to store 'homed' state.

Please Log in to join the conversation.

More
4 years 3 months ago #248306 by andypugh

Code:
I'm reading the HAL component generator manual page, but '[i]make a homed pin not a parameter' is a bit Greek to me at this stage.[/i]
Currently line 137 is
Code:
param rw bit homed = 0 "Shows that homing is complete. Only used in index and edge modes";

Edit that to be
Code:
pin out bit homed = 0 "Shows that homing is complete. Only used in index and edge modes";
and it will be a pin, and able t be added to a net. 

But: With the current r/w parameter it is possible to setp the param to zero to unhome the carousel. That won't work any more with an out pin. 
(You _could_ create the pin as io, but that would be a bit unusual, the only bidirectional io pins in common use in LinuxCNC are the index-enable, and it is debatable whether that was a good design decision. 
 

Please Log in to join the conversation.

More
4 years 3 months ago #248322 by spumco
Code:
But: With the current r/w parameter it is possible to setp the param to zero to unhome the carousel. That won't work any more with an out pin. 

Hmm...thoughts:
  • Unhoming carousel during testing is extremely useful
  • Unhoming carousel during an estop would also be useful
    • In my case I can envision a mid-program, mid-toolchange estop event.  It would be nice to recover without shutting down LCNC and restarting. i.e. untangle ATC, rehome axes, rehome carousel, back in business.
  • Reading state of 'is-homed' is also useful
    • Using 'is-homed' to pass state to ngc files as a go/no-go state for toolchange operations.
    • I know carousel.comp knows its own state, but in my case I want to pass that state to other things like spindle orientation and GUI components (ATC screen widget)

Please Log in to join the conversation.

More
4 years 3 months ago #248380 by andypugh
This version has homed as a pin, and a new "unhome" pin to, well, you can probably guess what it does.

It also might have better jogging behaviour.

Please Log in to join the conversation.

More
4 years 3 months ago #248382 by spumco
Thanks again Andy.

PDB cylinder suffered an o-ring failure last night it'll take me a couple days to source a new one - mill head top end is disassembled ATM.

I'll see if I can carefully test the new carousel without having to move the head or other stuff.

Please Log in to join the conversation.

Time to create page: 0.115 seconds
Powered by Kunena Forum