carousel component - stops short of correct pocket....sometimes
26 Dec 2017 13:16 #103641
by Henk
Hi
I am configuring a carousel tool changer on a milling machine using the carousel component.
The tool-chain has 30 pockets and is driven by a geneva-mechanism. Position feedback is from a binary encoder, so it is a perfect application for the carousel component.
For some unknown reason, the carousel sometimes stops short of the commanded position by two pockets. this happens only in the reverse direction, and not always.
in the forward direction, it stops 1 pocket short, also only sometimes. i couldnt figure out the pattern yet....
carousel.comp is enabled by iocontrol.tool-prepare and iocontrol.tool-prep-number is linked to carousel.0.pocket-number.
I have checked the encoding by jogging the toolchain and carousel.0.current-position follows the numbers on the hardware so this is correct.
Any ideas on where to look for this issue will be a great help.
BTW, i have compiled the latest version of carousel.comp from github
Thanks
Henk
I am configuring a carousel tool changer on a milling machine using the carousel component.
The tool-chain has 30 pockets and is driven by a geneva-mechanism. Position feedback is from a binary encoder, so it is a perfect application for the carousel component.
For some unknown reason, the carousel sometimes stops short of the commanded position by two pockets. this happens only in the reverse direction, and not always.
in the forward direction, it stops 1 pocket short, also only sometimes. i couldnt figure out the pattern yet....
carousel.comp is enabled by iocontrol.tool-prepare and iocontrol.tool-prep-number is linked to carousel.0.pocket-number.
I have checked the encoding by jogging the toolchain and carousel.0.current-position follows the numbers on the hardware so this is correct.
Any ideas on where to look for this issue will be a great help.
BTW, i have compiled the latest version of carousel.comp from github
Thanks
Henk
Please Log in or Create an account to join the conversation.
- Todd Zuercher
- Away
- Platinum Member
Less
More
- Posts: 5007
- Thank you received: 1441
26 Dec 2017 13:51 #103649
by Todd Zuercher
Replied by Todd Zuercher on topic carousel component - stops short of correct pocket....sometimes
Perhaps you may need to debounce some of your inputs?
Please Log in or Create an account to join the conversation.
26 Dec 2017 15:05 #103659
by andypugh
Replied by andypugh on topic carousel component - stops short of correct pocket....sometimes
Does the toolchanger have an index pin too?
Is the changer binary encoded or Gray coded? Gray-code is designed so that only one pin ever changes when you transition from one number to the next, but with a binary encoding you can see phantom numbers if all the switches change at different time.
For example 7 to 8:
0111 = 7
1000 = 8
If the switches all happen at different times, then the PC might actually see
0111 = 7
0011= 3
1010 = 10
1000 = 8
A separate index channel can be used to make the system only check the position when all the transitions have happened.
I don't think that debounce is a solution here.
Perhaps the carousel comp should "act suspicious" if it sees the position change by anything other than +/- 1
Is the changer binary encoded or Gray coded? Gray-code is designed so that only one pin ever changes when you transition from one number to the next, but with a binary encoding you can see phantom numbers if all the switches change at different time.
For example 7 to 8:
0111 = 7
1000 = 8
If the switches all happen at different times, then the PC might actually see
0111 = 7
0011= 3
1010 = 10
1000 = 8
A separate index channel can be used to make the system only check the position when all the transitions have happened.
I don't think that debounce is a solution here.
Perhaps the carousel comp should "act suspicious" if it sees the position change by anything other than +/- 1
Please Log in or Create an account to join the conversation.
28 Dec 2017 11:04 #103786
by Henk
Replied by Henk on topic carousel component - stops short of correct pocket....sometimes
Thanks Andy
i found the index pin (proxy) on the cam that rotates the geneva mechanism. I missed this in the wiring diagrams, my German is not so god .
i loaded 5 tristate_bit comps and used that to output the 5 binary bits, netted to carousel.0.senseNN, and it has solved the problem. Thanks for the advice
Henk
i found the index pin (proxy) on the cam that rotates the geneva mechanism. I missed this in the wiring diagrams, my German is not so god .
i loaded 5 tristate_bit comps and used that to output the 5 binary bits, netted to carousel.0.senseNN, and it has solved the problem. Thanks for the advice
Henk
Please Log in or Create an account to join the conversation.
28 Dec 2017 14:19 #103793
by andypugh
Replied by andypugh on topic carousel component - stops short of correct pocket....sometimes
I don’t know honk you need the tristates.
The carousel comp should let you connect the index directly if you have the latest version.
The carousel comp should let you connect the index directly if you have the latest version.
Please Log in or Create an account to join the conversation.
29 Dec 2017 03:40 #103811
by Henk
Replied by Henk on topic carousel component - stops short of correct pocket....sometimes
Thanks Andy. I compiled the latest version under "carousel1" so man carousel didnt show the latest info.... will remove the tristates and use the strobe input instead.
One other question.
This machine has a random tool changer, but the next tool is not exchanged with the tool in the spindle at tool change. Instead, the tool that was in the spindle is kept in the changer swing arm (it has two claws) and is stowed during the next tool change.
So, starting with tools and pocket numbers the same (tool1 - poc1, tool2-poc2.....etc), nothing in the spindle, and a program using :
M6 T1
...some code...
m6 t2
...some code...
m6 t3
some code
m2
This would result in
tool 0 in pocket 2
tool 1 pocket 3
and tool2 still in the changer swing arm.
Any idea how this could be configured? Random toolchanger only support changing the tool in spindle with the active pocket as far as i could see.
Thanks
Henk
One other question.
This machine has a random tool changer, but the next tool is not exchanged with the tool in the spindle at tool change. Instead, the tool that was in the spindle is kept in the changer swing arm (it has two claws) and is stowed during the next tool change.
So, starting with tools and pocket numbers the same (tool1 - poc1, tool2-poc2.....etc), nothing in the spindle, and a program using :
M6 T1
...some code...
m6 t2
...some code...
m6 t3
some code
m2
This would result in
tool 0 in pocket 2
tool 1 pocket 3
and tool2 still in the changer swing arm.
Any idea how this could be configured? Random toolchanger only support changing the tool in spindle with the active pocket as far as i could see.
Thanks
Henk
Please Log in or Create an account to join the conversation.
04 Jan 2018 15:53 #104024
by andypugh
Replied by andypugh on topic carousel component - stops short of correct pocket....sometimes
Is this actually functionally different from a conventional random toolchanger? It seems like the old tool is put back into the carousel during the unload?
I think it might be logically (if not physically) identical.
Can you annotate your example to show which tool is where at the beginning and after each stage?
I think it might be logically (if not physically) identical.
Can you annotate your example to show which tool is where at the beginning and after each stage?
Please Log in or Create an account to join the conversation.
06 Jan 2018 04:48 #104069
by Henk
Replied by Henk on topic carousel component - stops short of correct pocket....sometimes
Hi Andy
Random toolchanger doesn't end with the correct result. For example, starting with tools and pockets corresponding....
Tool Poc
0 0 (spindle - no tool loaded)
1 1
2 2
3 3
4 4
and calling M6 T1
Tool Poc
1 0 (tool 1 in spindle)
0 1 (poc 1 empty)
2 2
3 3
4 4
after calling M6 T2
Tool Poc
1 - (held in toolchanger)
2 0 (in spindle)
3 3
4 4
and after calling tool 3
Tool Poc
1 3
2 in toolchanger
3 in spindle
4 4
calling tool 4 results in
Tool Poc
1 3
2 4
3 in toolchanger
4 in spindle.
As you can see, the tool removed from the spindle during a change is kept in the toolchanger until the next toolchange is called.
For now I have solved this by remapping M6 and T. The subroutines for these updates numbered parameters that I have added to the .var file to make them persistent.
Is there a better solution?
Henk
Random toolchanger doesn't end with the correct result. For example, starting with tools and pockets corresponding....
Tool Poc
0 0 (spindle - no tool loaded)
1 1
2 2
3 3
4 4
and calling M6 T1
Tool Poc
1 0 (tool 1 in spindle)
0 1 (poc 1 empty)
2 2
3 3
4 4
after calling M6 T2
Tool Poc
1 - (held in toolchanger)
2 0 (in spindle)
3 3
4 4
and after calling tool 3
Tool Poc
1 3
2 in toolchanger
3 in spindle
4 4
calling tool 4 results in
Tool Poc
1 3
2 4
3 in toolchanger
4 in spindle.
As you can see, the tool removed from the spindle during a change is kept in the toolchanger until the next toolchange is called.
For now I have solved this by remapping M6 and T. The subroutines for these updates numbered parameters that I have added to the .var file to make them persistent.
Is there a better solution?
Henk
Please Log in or Create an account to join the conversation.
21 Jan 2018 11:57 #104778
by andypugh
Sorry for the delay, I have been working abroad the last few weeks (in fact, I still am).
The best solution would be to write a new version of iocontrol.cc for your specific machine.
github.com/LinuxCNC/linuxcnc/blob/master.../iotask/ioControl.cc
There is already one alternate version
github.com/LinuxCNC/linuxcnc/blob/master...task/ioControl_v2.cc
But changing that means recompiling LinuxCNC.
Your solution sounds OK, if it is working properly. I think I would be tempted to write a Python userpsace HAL component to handle the situation and to save the state to its own private file. But what you have done seems about as good as any other solution.
Replied by andypugh on topic carousel component - stops short of correct pocket....sometimes
Is there a better solution?
Sorry for the delay, I have been working abroad the last few weeks (in fact, I still am).
The best solution would be to write a new version of iocontrol.cc for your specific machine.
github.com/LinuxCNC/linuxcnc/blob/master.../iotask/ioControl.cc
There is already one alternate version
github.com/LinuxCNC/linuxcnc/blob/master...task/ioControl_v2.cc
But changing that means recompiling LinuxCNC.
Your solution sounds OK, if it is working properly. I think I would be tempted to write a Python userpsace HAL component to handle the situation and to save the state to its own private file. But what you have done seems about as good as any other solution.
Please Log in or Create an account to join the conversation.
22 Jan 2018 06:20 #104831
by Henk
Replied by Henk on topic carousel component - stops short of correct pocket....sometimes
Hi Andy
Thanks for the info.
Henk
Thanks for the info.
Henk
Please Log in or Create an account to join the conversation.
Time to create page: 0.090 seconds