Mori Seiki SL1 Turret PLC
Moderator: cnckeith
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Mori Seiki SL1 Turret PLC
Ive been doing as much research as possible to understand how this turret works. We are close to finishing up the retrofit and i'm looking to figure out how we are going get acorn to handle the 8 tool turret operation. The turret is hydraulically locked and unlocked and uses a 100v solenoid to do so. It contains 5 Normally Open DC 3-wire, NPN voltage output proximity sensors to detect tool position and 1 proximity sensor to detect if the turret is in the locked position. Looking at the table in the manual it shows the detection of the tool position is dependent on the activation of two of the proximity sensors i.e. Tool 1 would be the activation of sensor (A) and sensor (B), Tool 2 sensor (B) and (C). The motor that drives the turret is a 0.1kw 3 phase motor and from what I understand I should be able to set it to run forward and rev. So the sequence would need to trigger the solenoid to unlock the turret and the index to the correct position and then close the solenoid and check if closed. Any insight on this would be very helpful.
-
- Posts: 7327
- Joined: Wed Mar 03, 2010 4:23 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: Yes
- Oak CNC controller: Yes
- CNC Control System Serial Number: none
- DC3IOB: Yes
- CNC11: Yes
- CPU10 or CPU7: Yes
- Contact:
Re: Mori Seiki SL1 Turret PLC
Hello. looks like 5 bit turret logic. and would require 5 inputs on the Acorn.
ToolA IS INP1 ; 1 = bit set
ToolB IS INP2 ; 1 = bit set
ToolC IS INP3 ; 1 = bit set
ToolD IS INP4 ; 1 = bit set
ToolE IS INP5 ; 1 = bit set
IF ToolA AND ToolB THEN ToolNumber = 1
IF ToolB AND ToolC THEN ToolNumber = 2
IF ToolC AND ToolD THEN ToolNumber = 3
IF ToolD AND ToolA THEN ToolNumber = 4
IF ToolA AND ToolC THEN ToolNumber = 5
IF ToolB AND ToolD THEN ToolNumber = 6
IF ToolC AND ToolE THEN ToolNumber = 7
IF ToolD AND ToolE THEN ToolNumber = 8
A custom PLC program would be required and a Ether1616 to have enough i/o to run the rest of the items on the machine.
ToolA IS INP1 ; 1 = bit set
ToolB IS INP2 ; 1 = bit set
ToolC IS INP3 ; 1 = bit set
ToolD IS INP4 ; 1 = bit set
ToolE IS INP5 ; 1 = bit set
IF ToolA AND ToolB THEN ToolNumber = 1
IF ToolB AND ToolC THEN ToolNumber = 2
IF ToolC AND ToolD THEN ToolNumber = 3
IF ToolD AND ToolA THEN ToolNumber = 4
IF ToolA AND ToolC THEN ToolNumber = 5
IF ToolB AND ToolD THEN ToolNumber = 6
IF ToolC AND ToolE THEN ToolNumber = 7
IF ToolD AND ToolE THEN ToolNumber = 8
A custom PLC program would be required and a Ether1616 to have enough i/o to run the rest of the items on the machine.
Need support? READ THIS POST first. http://centroidcncforum.com/viewtopic.php?f=60&t=1043
All Acorn Documentation is located here: viewtopic.php?f=60&t=3397
Answers to common questions: viewforum.php?f=63
and here viewforum.php?f=61
Gear we use but don't sell. https://www.centroidcnc.com/centroid_di ... _gear.html
All Acorn Documentation is located here: viewtopic.php?f=60&t=3397
Answers to common questions: viewforum.php?f=63
and here viewforum.php?f=61
Gear we use but don't sell. https://www.centroidcnc.com/centroid_di ... _gear.html
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Re: Mori Seiki SL1 Turret PLC
Just getting around to this I do have the turret working on graycode right now with 4 sensors instead of 5. Only issue with this is two tools now only have 1 input off during tool changes instead of 2. So during a tool change when the sensors are being triggered, there is a false reading for two of the tools.
I sat down to write the code like you explained it and this is what I came up with.
Would something like this work?
I sat down to write the code like you explained it and this is what I came up with.
Code: Select all
IF !(ToolTurretPosBit3) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 1
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 2
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 3
IF !(ToolTurretPosBit2) && !(ToolTurretPosBit3) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 4
IF !(ToolTurretPosBit2) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 5
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit3) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 6
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit4) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 7
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit3) && SV_MACHINE_PARAMETER_161 >= 1 THEN CurrentTurretPosition_W = 8
IF TRUE THEN SV_PLC_CAROUSEL_POSITION = CurrentTurretPosition_W
Re: Mori Seiki SL1 Turret PLC
That looks like it would work, as long as nothing fails. Consider the case where you cut the wire that carries either +24V or 0V to the turret sensors. Then all five will be open/off, and the PLC logic will decide that the turret is in position #8 (since that is the last one it tested).
A more robust solution is to test all of the bits, both on and off. A concise way to do that, provided you have them defined on consecutive inputs, is to use BTW to pack them into an integer value, then test that integer value.
Suppose that you have defined:
If you imagine those five inputs are the bits of a 5-bit binary number, then it would have possible values from 0 to 31. The first switch has a value of +1; the second switch has a value of +2; the third switch has a value of +4; and so on.
To read the switches into a word variable and test it all at once, you would write:
If you wanted, you could add code to detect "none of the above" for an invalid switch pattern, and report an error if that condition persisted for more than a second or so.
A more robust solution is to test all of the bits, both on and off. A concise way to do that, provided you have them defined on consecutive inputs, is to use BTW to pack them into an integer value, then test that integer value.
Suppose that you have defined:
Code: Select all
ToolTurretPosBit1 IS INP41
ToolTurretPosBit2 IS INP42
ToolTurretPosBit3 IS INP43
ToolTurretPosBit4 IS INP44
ToolTurretPosBit5 IS INP45
;...
TurretBits_W IS W6
To read the switches into a word variable and test it all at once, you would write:
Code: Select all
IF True THEN BTW TurretBits_W TurretPosBit1 5
IF TurretBits_W == 3 THEN CurrentTurretPosition_W = 1 ; 1 + 2
IF TurretBits_W == 6 THEN CurrentTurretPosition_W = 2 ; 2 + 4
IF TurretBits_W == 12 THEN CurrentTurretPosition_W = 3 ; 4 + 8
IF TurretBits_W == 9 THEN CurrentTurretPosition_W = 4 ; 1 + 8
IF TurretBits_W == 5 THEN CurrentTurretPosition_W = 5 ; 1 + 4
IF TurretBits_W == 10 THEN CurrentTurretPosition_W = 6 ; 2 + 8
IF TurretBits_W == 20 THEN CurrentTurretPosition_W = 7 ; 4 + 16
IF TurretBits_W == 24 THEN CurrentTurretPosition_W = 8 ; 8 + 16
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Re: Mori Seiki SL1 Turret PLC
This is a great idea. What about parameter 830? Looking at the plc I can see each selection in p830 sets a stage to be active. Would this mean I need to write this in its own stage or just write it in a stage like Incremental and set p830 to that?
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Re: Mori Seiki SL1 Turret PLC
Here's where I'm at. Shouldn't I have to declare input on instead of !. I also created a new stage and declared it so this could be set in P830. I'm a little confused on how to implement the BTW.
Code: Select all
IF !(ToolTurretPosBit3) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 28
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 25
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 19
IF !(ToolTurretPosBit2) && !(ToolTurretPosBit3) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 22
IF !(ToolTurretPosBit2) && !(ToolTurretPosBit4) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 26
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit3) && !(ToolTurretPosBit5) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 21
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit4) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 11
IF !(ToolTurretPosBit1) && !(ToolTurretPosBit2) && !(ToolTurretPosBit3) && SV_MACHINE_PARAMETER_161 >= 1 THEN TurretBits_W = 7
IF TurretBits_W == 28 THEN CurrentTurretPosition_W = 1
IF TurretBits_W == 25 THEN CurrentTurretPosition_W = 2
IF TurretBits_W == 19 THEN CurrentTurretPosition_W = 3
IF TurretBits_W == 22 THEN CurrentTurretPosition_W = 4
IF TurretBits_W == 26 THEN CurrentTurretPosition_W = 5
IF TurretBits_W == 21 THEN CurrentTurretPosition_W = 6
IF TurretBits_W == 11 THEN CurrentTurretPosition_W = 7
IF TurretBits_W == 7 THEN CurrentTurretPosition_W = 8
Re: Mori Seiki SL1 Turret PLC
You take out all of the lines that test "ToolTurretPosBitn" inputs individually, and replace them all with a single line that says:
BTW stands for "bits to word". It is followed by three things:
1) The destination word (integer) variable: in this case, TurretBits_W
2) The first of the source bits: in this case, TurretPosBit1
3) The number of bits to read: in this case, 5
I could not speculate about where in your PLC program you should put those lines, or what you should do with Parameter 830, because I have not seen your PLC program.
Code: Select all
IF True THEN BTW TurretBits_W TurretPosBit1 5
1) The destination word (integer) variable: in this case, TurretBits_W
2) The first of the source bits: in this case, TurretPosBit1
3) The number of bits to read: in this case, 5
I could not speculate about where in your PLC program you should put those lines, or what you should do with Parameter 830, because I have not seen your PLC program.
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Re: Mori Seiki SL1 Turret PLC
I have it working but as you can see here it still reads 7 & 8 between some other tool numbers.
- Attachments
-
- report_780473A92571-0930192501_2020-11-25_22-32-44.zip
- (724.51 KiB) Downloaded 103 times
-
- ACORN_Gray_Code_2_Motor_Output_Turret_r1.src
- (201.34 KiB) Downloaded 93 times
-
- Posts: 9914
- Joined: Tue Mar 28, 2017 12:01 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: Yes
- Oak CNC controller: No
- CNC Control System Serial Number: none
- DC3IOB: No
- CNC12: Yes
- CNC11: Yes
- CPU10 or CPU7: Yes
- Location: Mesa, AZ
Re: Mori Seiki SL1 Turret PLC
Are you sure you have the turret logic properly connected? You are sure of the sensor voltages. Have you inspected the sensors themselves?
Do you know if it was working with the old control before your upgrade?
Just offering some suggestions.
Marty
Do you know if it was working with the old control before your upgrade?
Just offering some suggestions.
Marty
Reminder, for support please follow this post: viewtopic.php?f=20&t=383
We can't "SEE" what you see...
Mesa, AZ
We can't "SEE" what you see...
Mesa, AZ
-
- Posts: 48
- Joined: Tue Dec 03, 2019 10:40 pm
- Acorn CNC Controller: Yes
- Allin1DC CNC Controller: No
- Oak CNC controller: No
- CNC Control System Serial Number: 780473A92571-0930192501
- DC3IOB: No
- CNC12: Yes
- CNC11: No
- CPU10 or CPU7: No
Re: Mori Seiki SL1 Turret PLC
I've have it working now its not reading tools in between changes. Last thing to do is set the cnctch.mac to open and close the turret hydraulics and look for the tool change complete bit.