Ether 1616 controlled Stepper

All things related to the Centroid Acorn CNC Controller

Moderator: cnckeith

martyscncgarage
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: Ether 1616 controlled Stepper

Post by martyscncgarage »

mick41zxr wrote: Sun Jan 12, 2020 10:07 pm Marty do you have details or link on your Emcoturn setup. All info is usefull, as the idea is to make the process as reliable as possible.
Thanks
Yes, here is a video I did on it:


The Geckodrive G216 IS available from Geckodrive. You have to call and ask for it. Let them know you saw the video I made and the reference to the drive. Its a very handy tool to have in your "toolbox" that this drive can control a stepper motor just like a regular DC motor.

A typical Carousel tool changer has two sensors. One specifically for tool 1. Another that counts the tools. You could drive your stepper like a motor with the G216 and CNC12 could control the ATC. Of course as you know, there is more to the whole tool change than that. BUT Centroid does havea a "typical" Umbrella PLC that could be used as a jumping off point.

Marty
Reminder, for support please follow this post: viewtopic.php?f=20&t=383
We can't "SEE" what you see...
Mesa, AZ
mick41zxr
Posts: 181
Joined: Thu May 17, 2018 8:19 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Ether 1616 controlled Stepper

Post by mick41zxr »

Greatly appreciated Marty.
I will post up logic of what is going on inside PLC & digest what you recommend.
Thanks
Muzzer
Posts: 728
Joined: Mon Feb 19, 2018 2:52 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 38D269594F9C-0110180512
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: UK
Contact:

Re: Ether 1616 controlled Stepper

Post by Muzzer »

Mick - I was provoked into buying an ACE 222v10 PLC after seeing your work. Could you post your logic so I can see how you implemented the controls please? Doesn't need to be complete but would give me an idea. They look rather fragile electrically but seem to be fairly powerful for the price, much of that coming from the versatility of the software.

Marty / Keith - are the Acorn general outputs (including the Ether1616 relays) the only way to send signals to external peripherals? Modbus would be nice but unless I missed something, there's no such provision on Acorn. Sending signals via relays is almost like semaphore in terms of speed but my std higher speed Acorn outputs are mostly accounted for.

How is the Gray code implemented? Is there a std(?) lump of macro code that does it?
martyscncgarage
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: Ether 1616 controlled Stepper

Post by martyscncgarage »

No modbus.
Inputs only
Gray code is a group of logic bits set high or low by the device. In most cases a turret. The manufacturer usually provides a truth table correlating with the tool number.

Marty
Reminder, for support please follow this post: viewtopic.php?f=20&t=383
We can't "SEE" what you see...
Mesa, AZ
carbuthn
Posts: 199
Joined: Tue Jan 15, 2019 11:40 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No

Re: Ether 1616 controlled Stepper

Post by carbuthn »

Mick,

If you have a PLC it can send out about anything to the controller. It can translate from the Either 1616 to a number or a position.

The number of outputs depend on the number of tool, 3 for 8 tools, 4 for upto 16 tools and 5 for 32 tools.

0000 = 0
0001 = 1
0010 = 2
0011 = 3
0100 = 4
0101 = 5
0110 = 6
0111 = 7
1000 = 8
1001 = 9
1010 = 10
1011 = 11
1100 = 12
1101 = 13
1110 = 14
1111 = 15

Each bit on the left is an on or off of a relay. The translation can be done by a PLC with 4 input and the number sent by modbus from the PLC. With a little programing it may be able to step and direction to a driver and monitor current position. https://www.youtube.com/watch?v=CsJcDrJHZrs
Chuck
Muzzer
Posts: 728
Joined: Mon Feb 19, 2018 2:52 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 38D269594F9C-0110180512
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: UK
Contact:

Re: Ether 1616 controlled Stepper

Post by Muzzer »

What you've posted there is actually standard binary, not Gray code. Gray code only changes one digit at a time between increments. Here's how they compare:

Dec Bin Gray
0 0000 0000
1 0001 0001
2 0010 0011
3 0011 0010
4 0100 0110
5 0101 0111
6 0110 0101
7 0111 0100
8 1000 1100
9 1001 1101
10 1010 1111
11 1011 1110
12 1100 1010
13 1101 1011
14 1110 1001
15 1111 1000

My ATC is 32 position, so will require 5 bits. I understand how I might convert Gray code inputs to a position number in general terms but I'd like to see how others have done it in a macro rather than sit down to invent a wheel. Hopefully Mick will post his code for us to see, even if it's very much work in hand.
cncsnw
Posts: 3855
Joined: Wed Mar 24, 2010 5:48 pm

Re: Ether 1616 controlled Stepper

Post by cncsnw »

There are conversion algorithms on the Wikipedia page here: https://en.wikipedia.org/wiki/Gray_code

That page also has a good description of why Gray code is desirable in control systems like ours.
mick41zxr
Posts: 181
Joined: Thu May 17, 2018 8:19 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Ether 1616 controlled Stepper

Post by mick41zxr »

Sorry been away,
The way its been set is opposite to the way Marty describes. Acorn is sending out 4 bits in grey or std binary to tell an external PLC the postition to translate to. This way you will have to define each tool pocket position in Mfunc6.mac. Marty's way is possibly superior & would work really well with a Geneva mechanism type carousel.
The other reason I went down this path was that I have DMM driving the Axis & using the A axis for the carousel made it expensive or you limited the frequency the other Axis could use if a stepper was used for the carousel.
Muzzer my PLC file from Velocio builder is attached.
Car7.zip
(6.56 KiB) Downloaded 153 times
It uses 5 input bits, 4 postion bits (1-4) for grey code, then an enable/actuate bit (5) to trigger motion.
bit 5 is also used to home the carousel on startup. you will also need a prox sensor to home the carousel to.
Hopefully it will make sense when you see it. I was also thinking of adding a reset bit to re-home the carousel without having to power down then power up again.
I will add my mfunc6.mac when I get to it shortly, too many projects on the go at the moment.
Regards,
Michael
martyscncgarage
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: Ether 1616 controlled Stepper

Post by martyscncgarage »

mick41zxr wrote: Mon Jan 27, 2020 5:34 am Sorry been away,
The way its been set is opposite to the way Marty describes. Acorn is sending out 4 bits in grey or std binary to tell an external PLC the postition to translate to. This way you will have to define each tool pocket position in Mfunc6.mac. Marty's way is possibly superior & would work really well with a Geneva mechanism type carousel.
The other reason I went down this path was that I have DMM driving the Axis & using the A axis for the carousel made it expensive or you limited the frequency the other Axis could use if a stepper was used for the carousel.
Muzzer my PLC file from Velocio builder is attached.
Car7.zip
It uses 5 input bits, 4 postion bits (1-4) for grey code, then an enable/actuate bit (5) to trigger motion.
bit 5 is also used to home the carousel on startup. you will also need a prox sensor to home the carousel to.
Hopefully it will make sense when you see it. I was also thinking of adding a reset bit to re-home the carousel without having to power down then power up again.
I will add my mfunc6.mac when I get to it shortly, too many projects on the go at the moment.
Regards,
Michael
Negative,
The four bits come from the Turret's 4 optical encoders....
They are connected to the Ether1616 inputs.
CNC12 monitors the 4 inputs. CNC12 has been programmed to meet the turret truth table.
Reminder, for support please follow this post: viewtopic.php?f=20&t=383
We can't "SEE" what you see...
Mesa, AZ
mick41zxr
Posts: 181
Joined: Thu May 17, 2018 8:19 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Ether 1616 controlled Stepper

Post by mick41zxr »

Thanks Marty,
I meant opposite in the way that in your setup Acorn is reading position from the turret. Where in my carousel Acorn is sending position to the motor controller (PLC).
I think possibly your way is superior as Acorn at all time knows exactly where the turret/carousel is located & you can use Acorns internal PLC. I believe that this setup would suit any setup that positively located the turret/carousel, i.e. ratchet & spawl or geneva mechanism.
The way I set relies on the reliability of the stepper. In this instance I used a cheap closed loop stepper to ensure position.
Regards,
Michael
Post Reply