Denford Triac Carousel ATC

All things related to the Centroid Acorn CNC Controller

Moderator: cnckeith

Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Can I also check. plc.src, where is that? I can only see acorn_mill_plc.src. Is that in effect the file you are referring to?


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Also, I can see ATCCarouselReverse and ReverseToolTurret (as an option in the ATC dropdown). Is there a specific use case for either? It sounds like the first is for a typical Carousel and the 2nd might be on a lathe?


Greg
Posts: 37
Joined: Wed Feb 03, 2021 11:12 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: Denford Triac Carousel ATC

Post by Greg »

Mario did a whole series of video's on plc programming. Its a lot of information but I would give them a watch first.



Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Greg wrote: Fri Jun 21, 2024 12:29 pm Mario did a whole series of video's on plc programming. Its a lot of information but I would give them a watch first.

Thanks. Had started to watch however also a bit time limited. Let me look at that again.

Thanks


Greg
Posts: 37
Joined: Wed Feb 03, 2021 11:12 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: Denford Triac Carousel ATC

Post by Greg »

you will need to compile it correctly and yes that is the right plc file. You are also correct about the ToolTurret being for a lathe style atc. Learning custom PLC can be a big time suck but understanding it will save a lot of frustration. Centroid is easy to use but getting my atc working correctly was by far the most difficult part.


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Guys, what's wrong with this, why cant I trigger an output on the Ether1616?

This is M63.func that I'm editing so that I should be able to use M63

;------------------------------------------------------------------------------
; Filename: mfunc63.mac
; Wizard ATC_CarouselIn M-code Macro: M63
; Description: User Customizable Macro
; Notes: Use Acorn Wizard i/o map to set Eth1616 to 33 for ATC_CarsouselIn
; Requires:
; Please see TB300 for tips on writing custom macros.
;------------------------------------------------------------------------------

IF #50010 ;Prevent lookahead from parsing past here
IF #4201 || #4202 THEN GOTO 1000 ;Skip macro if graphing or searching

N100 ;Insert your code between N100 and N1000

M94 /63 ;Request ATC_CarouselIn

N1000 ;End of Macro

How else can I trigger Output 33 onwards on the Eth1616 via a Macro?

I realise the Request is behind a ; comment, so how do I define it?


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Why does this code M94/120 or M94/117 do nothing? 120 is not mapped (says output 36, so tried 117 which is 33, surely)?

Page 12 in this manual refers - https://www.centroidcnc.com/centroid_di ... ctions.pdf
Outputs.png
As the ATC code does use the outputs, it does exist. Why cant I manually enable / disable via M Codes? I dont want to use the default macro as it doesnt work for me and I'd prefer not to edit the .src as I believe I can emulate what I need via Macro however I have to be able to manually trigger an Ether1616 output. I can move it to the Non Ether board but that defeats the purpose - what am I missing please?


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

Is there meant to be anything define here in the .src file like the M61 to M68 is?
Screenshot 2024-06-23 192522.png


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

OK. Ive moved on from trying to do it this way and using Outputs that I can actually address. This is all working fine and I have some base automation sorted. Just working through the detail of how to count / decrement a counter each time an input changes state .... so that I can tell how many times the geneva motor has rotated. Any tips would be appreciated.

N300

#151 = #4120 ;Save the requested tool change into variable 151, might not be needed but it's there.

#152 = #4203 ;Save the current tool as variable 152, as per above.

#155 = (#4120 - #150) - #152 ;Variable 155 is the number of times I believe the geneva wheel needs to turn (might not be accurate but I can figure it out later).

;Code to determine Rotate Carousel

M68 ;Rotate Carousel FWD - switch on the Carousel Forward

;Code to count / decrement the 155 variable (this isnt working at the moment)
N310
M101/50033 ;Wait for a trigger on the 1st Acorn Eth1616 Input
#155 = #155 - 1 ; If I see an input on Eth1616 1'st input port, then decrement Var 155 with 1
G4 P1 ;To stop this happening immediately, I wait a second
IF #155 == 0 THEN GOTO 325 ELSE GOTO 310 ;

How else can I count and increase or decrease pending a input changing state please?

Thanks
Last edited by Chaz on Mon Jun 24, 2024 11:57 am, edited 1 time in total.


Chaz
Posts: 694
Joined: Thu Feb 08, 2018 7:57 am
Acorn CNC Controller: No
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC11: No
CPU10 or CPU7: No

Re: Denford Triac Carousel ATC

Post by Chaz »

OK, slow progress, struggling with M225 but got some working (ironically just copied / pasted someone else which worked and mine was identical), but nevermind.

How do I customise message? If I want to display a value which is calculated and stored in #155.

M225 #100 "The Calculated value in 155 is ... " #155 ?

This doesnt work.


Post Reply