- Configuring LinuxCNC
- Advanced Configuration
- Spindle Step/Dir servo ramp down before stop on M stop command.
Spindle Step/Dir servo ramp down before stop on M stop command.
Is C showing a "homed" marker in the DRO at this point?
Yes, X,Z and C have the little marker left of the axis letter.
I think that this is just Axis GUI behaviour. If you switch to the MDI window then the machine is put in MDI mode. You can only jog in Manual mode. Just switching to the Manual tab is probably enough to re-enable jogging.
You are correct ( partially?) -
went to test again just to be sure -
Home all - home marker present on all three - X and Z physically moved to the home sensor, etc. C axis did not move.
X and Z axes all jog manually ok
However - jogging the C axis with the handwheel causes the C axis DRO to increment/decrement ). The axis itself does not move - it is not enabled) - I apologize for this - the axis DRO does jog, the axis itself does not - I had intimated both did not work.
Then MDI screen selected - Axes still jog OK with handwheels as above.
Then M100 - now no axes jog with handwheels anymore.
Go to Manual screen - All axes jog again, now C moves as well, since it is in M100.
Back to MDI screen - all Axes still jog OK.
Then do M101
Now no axes jog anymore.
Go back to manual screen and X and Z axes jog fine again, C DRO works, with C axis not moving ( not active - M101)
I misled you in saying the 'axis' does not jog - the DRO 'jogs' , but the axis does not move if it is not enabled..
I will try the pid.c.maxoutput fix and let you know what happens..I think that is neat!
Please Log in or Create an account to join the conversation.
I am working on a similar system with success with some glitches. (The delays are not always preventing a follow error. )
I am using a MESA 7i92 board.
I have M101 (to switch to C mode)
#!/bin/bash
#SWITCHES TO ANGLE MODE
halcmd setp hm2_7i92.0.stepgen.04.position-reset 1
sleep 1
halcmd setp hm2_7i92.0.stepgen.04.position-reset 0
sleep 1
halcmd unlinkp hm2_7i92.0.stepgen.04.velocity-cmd
halcmd net c-output hm2_7i92.0.stepgen.04.velocity-cmd
halcmd net c-pos-fb joint.4.motor-pos-fb
halcmd net c-pos-fb hm2_7i92.0.stepgen.04.position-fb
and M102 (switch back to spindle mode)
#!/bin/bash
# SWITCHES TO SPINDLE MODE
halcmd unlinkp hm2_7i92.0.stepgen.04.velocity-cmd
halcmd unlinkp joint.4.motor-pos-fb
halcmd unlinkp hm2_7i92.0.stepgen.04.position-fb
halcmd net spindle-mode spindle-ramp.out hm2_7i92.0.stepgen.04.velocity-cmd
Please Log in or Create an account to join the conversation.
halcmd setp hm2_7i92.0.stepgen.04.position-reset 1
This is the easy way to prevent a large error on switchover, but it has the disadvantage of not giving a repeatable zero for the C axis.
Please Log in or Create an account to join the conversation.
Then MDI screen selected - Axes still jog OK with handwheels as above.
Then M100 - now no axes jog with handwheels anymore.
This sounds very much like M100 puts the system in Auto mode. I am afraid that that is stock behaviour and not easy to work around.
You could _try_ adding
halcmd setp halui.mode.manual 0
sleep 1
halcmd setp halui.mode.manual 1
[quote[Go to Manual screen - All axes jog again, now C moves as well, since it is in M100.[/quote]
I had a lathe with a joypad and it used to annoy me that I had to switch to the manual tab to use it.
Please Log in or Create an account to join the conversation.
Also, in stepgen.c, I am working to wait before executing the position-reset action.
Please Log in or Create an account to join the conversation.
Like Do loops or if statements. ?
Please Log in or Create an account to join the conversation.
halcmd setp hm2_7i92.0.stepgen.04.position-reset 1
This is the easy way to prevent a large error on switchover, but it has the disadvantage of not giving a repeatable zero for the C axis.
This can be avoided by using an index input and stepgen index
If LinuxCNCs motion comp could be asked to rehome a joint including
the part where it forces its commanded joint position to equal the current
joint feedback position, this would be easier.
Please Log in or Create an account to join the conversation.
It seems to me that this indexing can be done in the Mesa firmware. This way we wont have to add a hardware encoder/indexer to the motor. In my case, I am using a teknic servo, and it does not/cannot miss a step, and does not have available encoder outputs. The only output it has is the fault output, which I connected to a fault input of the joint. It aborts if motor goes above its limits.
Following Errors on switch over:
Somehow, I need to add a loop to wait until joint speed is 0 and execute the position-reset. Adding arbitrary delays here and there works for some cases, and does not work for others.
I have tried this using a M201 in remap.py without much success.
Please Log in or Create an account to join the conversation.
you would just make a simulated index component in hal
Please Log in or Create an account to join the conversation.
I will look into creating a hal component.
Please Log in or Create an account to join the conversation.
- Configuring LinuxCNC
- Advanced Configuration
- Spindle Step/Dir servo ramp down before stop on M stop command.