CAROUSEL CONFIGURATION
14 May 2023 05:16 #271330
by rajsekhar
CAROUSEL CONFIGURATION was created by rajsekhar
I am planning to make a carousel 6 tool position for Lathe.
Following are the details:
Another question, If I use position sensor for each tool, what should be the correct arrangement? Should I put all six sensor in one radial line in different radius and put the stickers in those radius with one stricker on each tool position, so that one sensor corresponding to one tool is active at a time and the tools position can be known from sensor inpit?
Following are the details:
- Stepper drive
- Index sensor
Another question, If I use position sensor for each tool, what should be the correct arrangement? Should I put all six sensor in one radial line in different radius and put the stickers in those radius with one stricker on each tool position, so that one sensor corresponding to one tool is active at a time and the tools position can be known from sensor inpit?
Please Log in or Create an account to join the conversation.
14 May 2023 15:20 #271345
by andypugh
Replied by andypugh on topic CAROUSEL CONFIGURATION
I have just pushed an updated version of "carousel" to the 2.9 version.
I would suggest using this for a stepper-motor controlled carousel.
You will only need one sensor for "home" (pocket 1)
This version has a pin called "counts-target" which can be connected either to a stepgen or a PID linked to an encoder.
Note that you should set the stepgen scale to 1.0 and allow the carousel component to handle scaling.
I would suggest using this for a stepper-motor controlled carousel.
You will only need one sensor for "home" (pocket 1)
This version has a pin called "counts-target" which can be connected either to a stepgen or a PID linked to an encoder.
Note that you should set the stepgen scale to 1.0 and allow the carousel component to handle scaling.
Please Log in or Create an account to join the conversation.
18 May 2023 21:04 #271625
by Serg452
Replied by Serg452 on topic CAROUSEL CONFIGURATION
Is there the same for 2.8? For stepper
Please Log in or Create an account to join the conversation.
19 May 2023 10:19 #271660
by andypugh
Download the file here:
raw.githubusercontent.com/LinuxCNC/linux...onents/carousel.comp
Then install it on your system withIf that command does not work then you might first have to
Replied by andypugh on topic CAROUSEL CONFIGURATION
You can compile and install the 2.9 version on your 2.8 machine.Is there the same for 2.8? For stepper
Download the file here:
raw.githubusercontent.com/LinuxCNC/linux...onents/carousel.comp
Then install it on your system with
sudo halcompile --install carousel.comp
sudo apt-get install linuxcnc-uspace-dev
Please Log in or Create an account to join the conversation.
25 May 2023 14:55 #272154
by Henk
Replied by Henk on topic CAROUSEL CONFIGURATION
HI
I hope this is the appropriate thread to add on to...
Attempted to use the new version of the carousel.comp today and i found something that is not quite clear to me
Setup:
20 station tool carousel, driven by a servo motor with encoder (2500 ppr) feedback to linuxcnc, There is a 10:1 gearbox between the motor and the pinion that drives the carousel, which is also 10:1 reduction, resulting in 50000 counts per pocket.
The result is that there are 5 index pulses from the encoder per pocket, and there are 20 pockets.
counts target is fed into a pid component, and the enabling is from iocontrol.0.tool-prepare
There is a proximity switch at pocket 1, and the length of the striker is such that at least 2 index pulses will occur while the switch is active. this proxy is linked to carousel.0.sense-0
The problem i have is with homeing on first enable...
It homes almost immediately at the current position, irrespective of the index proxy at pocket 1.
This section in carousel.comp handles the homeing.
in this line, at the start of case 11 if ( ! index_enable || ((! old_index) && ind)){ // index found
It seems that it will home when the index_enable goes false, and it does not matter if sense-0 (ind) is true or false.
changing the condition to && instead of || seems to have solved it.
Am i on the right track or is do i have a configuration error somewhere else?
Thanks
Henk
I hope this is the appropriate thread to add on to...
Attempted to use the new version of the carousel.comp today and i found something that is not quite clear to me
Setup:
20 station tool carousel, driven by a servo motor with encoder (2500 ppr) feedback to linuxcnc, There is a 10:1 gearbox between the motor and the pinion that drives the carousel, which is also 10:1 reduction, resulting in 50000 counts per pocket.
The result is that there are 5 index pulses from the encoder per pocket, and there are 20 pockets.
counts target is fed into a pid component, and the enabling is from iocontrol.0.tool-prepare
There is a proximity switch at pocket 1, and the length of the striker is such that at least 2 index pulses will occur while the switch is active. this proxy is linked to carousel.0.sense-0
The problem i have is with homeing on first enable...
It homes almost immediately at the current position, irrespective of the index proxy at pocket 1.
This section in carousel.comp handles the homeing.
case 10: // start of homing homed = 0; homing = 1; motor_fwd = 1; motor_rev = 0; motor_vel = fwd_dc; motor_dir = 1; index_enable = 1; counts_target += scale * inst_pockets; old_index = 1; // ensure 0->1 cycle of home sensor state = 11; case 11: ;// waiting for index & pulse int ind = 0; if (inst_code == 'C'){ ind = sense(0); } else { ind = (sense(0) && sense(1)); } if ( ! index_enable || ((! old_index) && ind)){ // index found current_position = 1; homed = 1; homing = 0; active = 0; motor_fwd = 0; motor_rev = 0; motor_vel = 0; base_counts = counts - home_offset; counts_target = base_counts; if ( align_dc == 0) { state = 0; } else { timer = decel_time; state = 5; } } old_index = ind; break; // So that we don't see the tool1 pulse twice
in this line, at the start of case 11 if ( ! index_enable || ((! old_index) && ind)){ // index found
It seems that it will home when the index_enable goes false, and it does not matter if sense-0 (ind) is true or false.
changing the condition to && instead of || seems to have solved it.
Am i on the right track or is do i have a configuration error somewhere else?
Thanks
Henk
Please Log in or Create an account to join the conversation.
25 May 2023 20:22 #272169
by spumco
Replied by spumco on topic CAROUSEL CONFIGURATION
What is your encoder index signal connected to in HAL?
Reason I'm asking is that I don't think you need to close the servo loop to LCNC. You'd need feedback to to run a PID, but if the drive can move the motor appropriately without needing LCNC's PID, why bother? Just hook up an alarm signal if the drive trips or develops an internal following error.
In my config (using the latest version Andy posted), carousel is running open loop except for the single pocket sensor & flag. There's no encoder connection to LCNC (closed loop to drive).
Reason I'm asking is that I don't think you need to close the servo loop to LCNC. You'd need feedback to to run a PID, but if the drive can move the motor appropriately without needing LCNC's PID, why bother? Just hook up an alarm signal if the drive trips or develops an internal following error.
In my config (using the latest version Andy posted), carousel is running open loop except for the single pocket sensor & flag. There's no encoder connection to LCNC (closed loop to drive).
Please Log in or Create an account to join the conversation.
26 May 2023 05:57 #272188
by Henk
Replied by Henk on topic CAROUSEL CONFIGURATION
I understand that there are other options to make it work, however the man page for carousel leads one to use a pid to do the position control..., and i dont understand the homeing logic as described above.
The encoder index-enable is connected to carousel.0.index-enable, as it should be. The encoder scale is set to 1 so that the units is in counts, and the encoder position is used as feedback to the pid, while the rawcounts is connected to carousel.0.counts, also as indicated by the man page.
After some thinking, i think that the intention with the homeing is intended to use either sense-0 input or encoder index, not both as i initially thought.
for a toolchanger, a simple switch should be good enough anyway...
Henk
The encoder index-enable is connected to carousel.0.index-enable, as it should be. The encoder scale is set to 1 so that the units is in counts, and the encoder position is used as feedback to the pid, while the rawcounts is connected to carousel.0.counts, also as indicated by the man page.
After some thinking, i think that the intention with the homeing is intended to use either sense-0 input or encoder index, not both as i initially thought.
for a toolchanger, a simple switch should be good enough anyway...
Henk
Please Log in or Create an account to join the conversation.
10 Jun 2023 10:36 #273264
by andypugh
Replied by andypugh on topic CAROUSEL CONFIGURATION
Which version of carousel are you using? There is a version in 2.9 that can use direct encoder feedback, though I am not sure that this helps here.
I think you need to ignore the encoder index, and only use the home flag as the index signal into LinuxCNC. This might mean wiring the flag into the index input on the Mesa board, though I can think of other ways that might work.
I think you need to ignore the encoder index, and only use the home flag as the index signal into LinuxCNC. This might mean wiring the flag into the index input on the Mesa board, though I can think of other ways that might work.
Please Log in or Create an account to join the conversation.
13 Jun 2023 13:11 #273485
by Henk
Replied by Henk on topic CAROUSEL CONFIGURATION
Hi
I downloaded and compiled the new version from master.
i removed the index-enable net in the hal file and only connected the index proxy to sense-0, which worked as expected. as mentioned, accuracy with the index proximity sensor is good enough. Most tool changers rely on them anyway
I downloaded and compiled the new version from master.
i removed the index-enable net in the hal file and only connected the index proxy to sense-0, which worked as expected. as mentioned, accuracy with the index proximity sensor is good enough. Most tool changers rely on them anyway
Please Log in or Create an account to join the conversation.
Time to create page: 0.191 seconds