need Acorn PLC output trigger in HOM file

All things related to the Centroid Acorn CNC Controller

Moderator: cnckeith

Post Reply
pmchoudek
Posts: 28
Joined: Fri Dec 11, 2020 3:23 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 2650
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No

need Acorn PLC output trigger in HOM file

Post by pmchoudek »

Hi there, I need to be able to control my Acorn's outputs.

Look at the acorn_mill_plc.src file starting at line 3211

I need my Acorn to send on it's output W72 = 6 Program Finished when the homing cycle is complete as well as any other program file (.cnc file).

I tried to add "Program_Finished_M = 1" at the end of my .HOM file but that caused an error.

I have an external PLC that is receiving these binary codes (xxxx) and doing different things.

Please help,

PC
Attachments
report_0C1C570715C2-1107192650_2021-03-05_13-36-54.zip
(747.1 KiB) Downloaded 89 times
pmchoudek
Posts: 28
Joined: Fri Dec 11, 2020 3:23 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 2650
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No

Re: need Acorn PLC output trigger in HOM file

Post by pmchoudek »

In my .HOM file, the program running is set (the output sends binary 0011 or 3 in decimal) when the homing sequence begins. It does not send binary 0110 or 6 in decimal when the homing sequence is complete.
Allin1Chris
Posts: 135
Joined: Wed Jul 31, 2019 12:53 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: Yes
CNC Control System Serial Number: none
DC3IOB: Yes
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: Yes

Re: need Acorn PLC output trigger in HOM file

Post by Allin1Chris »

Hello pmchoudek,

Try adding M94 /10 at the end of your home program.

Looking at your Custom PLC this is what is written.

Code: Select all

Program_Done_M_Code   IS SV_M94_M95_10; SET TurnClampOn, M11 RST TurnClampOn

;-----Program Finished----;
IF TRUE THEN Program_Finished_Delay_T = 25

IF Program_Done_M_Code THEN (Program_Finished_PD)
 
IF Program_Finished_PD THEN SET Program_Finished_M, SET Program_Finished_Delay_T

IF Program_Finished_M THEN W72 = 6

IF Program_Finished_Delay_T THEN RST Program_Finished_M, RST Program_Finished_Delay_T, W72 = 0

So for you to get W72 to = 6 you must activate "Program_Done_M_Code" which will be a M94 /10. The PLC will then automaticlly reset this bit and set W72 back to 0 after 25ms due to the Timer Program_FInished_Delay_T.

I suggest checking out our PLC manual that breifly goes over M94 M95 commands in the PLC. Starting on page 68 "Custom M-Codes". If your interested in learning more about PLC programming. Also check out the video series in my Signature for Centroid PLC programming.
https://www.centroidcnc.com/centroid_di ... manual.pdf

Additional information on M-codes can also be found in our Mill or Lathe manuals found on the centroid Website
When requesting support READ THIS POST first. http://centroidcncforum.com/viewtopic.php?f=60&t=1043

Please ALWAYS post a FRESH report. To make a report: https://www.youtube.com/watch?v=Ecvg0VJp1oQ.

(We pride ourselves on providing timely solid technical support but, without good information we may not be able to help and/or reply until such information is posted.)

Centroid PLC Tutorial Videos
cnckeith
Posts: 7292
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: need Acorn PLC output trigger in HOM file

Post by cnckeith »

All Acorn documentation is here.
viewtopic.php?f=60&t=3397

Introduction to Centroid Macro Programming is here
https://www.centroidcnc.com/centroid_di ... amming.pdf
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
pmchoudek
Posts: 28
Joined: Fri Dec 11, 2020 3:23 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 2650
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No

Re: need Acorn PLC output trigger in HOM file

Post by pmchoudek »

Thank you for the suggestion! I was a little confused on how and when the binary signals were being sent. It would send the 'program running' signal after every operation it seemed like. Where I was thinking it was only sending that signal when the job file was started... I was not the one who designed the program in the PLC, but thank you for helping me understand.

After testing the m94/10, I found out that it does work to send the 'program finished', but then realized what I described above. So I just kept the M94/10 omitted from my home file. I think my issues were better solved in my external PLC than in the Acorn.
Post Reply