Show me your Custom VCP's!

All things related to the Centroid Acorn CNC Controller

Moderator: cnckeith

Chipwelder
Posts: 25
Joined: Sun Apr 28, 2019 12:16 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 102139, 20D7787D9392-0817226460
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No

Re: Show me your Custom VCP's!

Post by Chipwelder »

Thanks Tom,
I tried to disclose my tool box limitations in my Profile but due to limited tools couldn't. One of those is Weed Hopper level Apprentice Code Monkey. It is Bad Practice to encourage me to tamper with code, but my M.S, in I.E. compels my left handed brain to locate anything in a set or operating procedures or processes and propose an upgrade. Enough said on that subject at this point.
After posting above and having it actually post I can verify that the green and red buttons in the spindle region of the default VPC screen are indeed labeled as Spindle On and Off with skin events 16,17 . Apologize for lack of Report. I am sitting in warm office 85 yds thru 12" of blowing snow at 4degrees F.from cold shop. I looked at my current plc file and it has correct buttons with skin event numbers but they are not in the Wizard chart. It appears to my level of code monkey that an If Then code line in plc would add Spindle on off buttons to Wizard list,(Wizard list formatting graphic considerations may preclude). One Could swap usable button for useless button if above rules. I will try on my next expedition to the shop to see the if I can trick the wizard by using the M3 button to do this. Then risk tampering with the button svg file to relabel and move that button to the preferred spot. But to address industry legacy human engineering concerns related to emergency response considerations(safety) and dichromatism(color blind operators), I want to use 2 buttons to toggle one output on and off without adding additional logic hardware(like old fashion forward reverse switches used on single phase ac motors) to turn my spindle relay(non-latching) on and off. It looks to me that the current Wizard can only link one button (with toggling code) to one Output. I am getting closer but my head hurts and am trying to avoid frostbite from extra trips to shop.
Again thanks for help to date.
tblough
Posts: 3072
Joined: Tue Mar 22, 2016 10:03 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: Yes
CNC Control System Serial Number: 100505
100327
102696
103432
7804732B977B-0624192192
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Boston, MA
Contact:

Re: Show me your Custom VCP's!

Post by tblough »

Can you draw a schematic of what you are trying to accomplish? The Acorn outputs are double-throw, when one output is on, the other is off. It sounds like you are trying to reinvent the wheel.
Cheers,

Tom
Confidence is the feeling you have before you fully understand the situation.
I have CDO. It's like OCD, but the letters are where they should be.
cncsnw
Posts: 3765
Joined: Wed Mar 24, 2010 5:48 pm

Re: Show me your Custom VCP's!

Post by cncsnw »

Perhaps the list of functions you are looking at in the wizard, are accessory functions often mapped to Auxiliary keys.

Spindle start and stop are core functions inherently supported by the spindle start/stop/direction keys, as well as by the M3 and M4 requests.

If you have a spindle connected to an output, and you want to turn it on and off with the existing spindle start/stop keys, then you just need to use the wizard to assign "SpinFWD" or "VFDEnable_O" to that output. Then it will do all the many things that a spindle is normally expected to do.

If for some reason you require an output that does none of the things a spindle is normally expected to do, except to start when you press the start button and stop when you press the stop button, then you will need to add your own PLC code. To avoid unwanted interference from the pre-existing feature set, you will probably want to use completely independent output names. There would be no harm in responding to skin events 16 and 17, as long as you did not have any other outputs assigned that are affected by the default spindle control features. However, it might be cleaner to make your own start and stop buttons (beginning as copies of the existing ones) with your own, previously-unused skin event numbers.
Chipwelder
Posts: 25
Joined: Sun Apr 28, 2019 12:16 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 102139, 20D7787D9392-0817226460
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No

Re: Show me your Custom VCP's!

Post by Chipwelder »

Tom, I have that too.
Moving on. There is a Wizard button for Spindle cancel that is tied to the red spindle off key in the default VCP. Through out the acorn_mill_prc.src there are numerous instances of spindle on and off with different specific character spellings(I think most of these are in the comments so wouldn't execute as spelled). But in the button file there are spindle_start(skin event 17) and spindle_cancel(se 16).
I am starting to get lost in all of the files. Here is what I think I know. The two buttons I need already exist in the default VCP they are the red(preprogramed M5) and green buttons(Preprogrammed M3,M5) mapped at R4,C1 and R4,C2. They have preprogrammed M codes triggered by skin events 16,17. Neither of which show in the ACORN CNC 12v4.8x Acorn Wizard Int and Output "canned"PLC functions and M code 7-25-20(this document is obsolete and needs to be updated). Never the less either. The current wizard cannot do this. It will have to be done editing the macros in the PLC file and assigning to the correct output, and that is too dangerous for me to attempt. I tried to use the Flood on off button via the Wizard to toggle an output on and off. It didn't work--See attached Report file.
Attachments
report_20D7787D9392-0817226460_2023-02-02_19-56-20.zip
(764.34 KiB) Downloaded 8 times
cncsnw
Posts: 3765
Joined: Wed Mar 24, 2010 5:48 pm

Re: Show me your Custom VCP's!

Post by cncsnw »

You have the data flow confused.

Pressing the Spindle Start key does not execute M3 or M4. Pressing the Spindle Stop key does not execute M5.

Instead, running the M3, M4 and M5 macros in a CNC program is one way of sending spindle start/stop/direction requests to the PLC program.
Pressing the keys on the jog panel is another way of sending spindle start/stop/direction requests to the PLC program.
Other actions, such as tripping a limit switch, pressing emergency stop, or triggering a fault are still more ways of sending spindle stop requests to the PLC program.

The PLC program receives all those requests from disparate sources; applies numerous logic rules; and finally decides which output relays, if any, to turn on or off.

There is no "M3 macro" in the PLC program. The M3 macro, if it exists, is a CNC file located in your c:\cncm directory. Because M3 is an inherent function with default behavior coded into CNC12, an M3 macro file is not required at all; but most Acorn installations have one. In any event, M3 is a CNC function, applicable only when running a CNC program cycle, and what it ultimately does (in most cases) is turn on the SV_M94_M95_1 requested bit in the PLC program.
Chipwelder
Posts: 25
Joined: Sun Apr 28, 2019 12:16 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 102139, 20D7787D9392-0817226460
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No

Re: Show me your Custom VCP's!

Post by Chipwelder »

Someone suggested I post a schematic showing what I am trying to do it is attached.
tblough-all of the coding and ski events already exist in the PLC that the Acorn board accesses. It is easily demonstrated using the int out put diagnostic screen and force toggling any of the outputs. The buttons with their skin event numbers are also defined. The green and the red buttons located at 4,1(spindle _cancel, skin event 16) and 4,2(spindle_start, skin event 17) on the default vcl. Also of note is the Single Auto Man button at 1,2 That allows the spindle to be turned on and off in manual mode and be controlled by M3 and M5 within a g-code program. I think it may also automatically turn the single off if M5 is not programmed in the g-code file being run. But it is there and when you "press" it I can see changes on the main screen indicating that the logic is being executed.
Tom--I think you asked for the schematic. I cut and pasted from a Centroid schematic then parked a screen shot of the default VCP on top and circled buttons related to my issue.
What I am trying to do is turn my spindle on and off using one output and the two preprogramed red and green spindle on/off buttons. There is an example in the Centroid 10cnc PLC manual around page 21 but it does not show me how to execute the XOR logic in ACORN and link it to the on/off buttons and OUTPUT5(or any other output).
The existing Wizard has an abbreviated list of buttons and doesn't seem to include the most important ones. I tried to use the flood_coolant 5,3 and used the Wizard to drag it to the output box and wrote it to the software but it doesn't function. The attached report should show what I actually did maybe and why it doesn't work. It sold toggle the output on and off with consecutive pushes(Doesn't have XOR like like the spindle buttons the use two buttons to selectively toggle one output) but should still toggle the output on and off.
router schematic bitmap.bmp
Attachments
report_20D7787D9392-0817226460_2023-02-04_16-48-29.zip
schematic file won't attach getting "file extension error"
(755.64 KiB) Downloaded 10 times
Chipwelder
Posts: 25
Joined: Sun Apr 28, 2019 12:16 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 102139, 20D7787D9392-0817226460
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No

Re: Show me your Custom VCP's!

Post by Chipwelder »

My schematic file is a .bmp
Chipwelder
Posts: 25
Joined: Sun Apr 28, 2019 12:16 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 102139, 20D7787D9392-0817226460
DC3IOB: No
CNC12: Yes
CNC11: Yes
CPU10 or CPU7: No

Re: Show me your Custom VCP's!

Post by Chipwelder »

CNCSNW Because I am not a code monkey my gramatical responses are not logically correct but try to step back out of code expert mode and help me get the green button to turn my spindle on and the red button to turn it off respecting the auto manual button above them.
I can follow your answer as I posted with the airspindle example in the CNC10 PLC manual. But I don't have a clue where(in the PLC file) the SV_M94_M95_1 code is. Seems this information should be in the VCP manual and why is it not in the Wizard? Can we get this basic OUTPUT/ Button programming into the wizard?
Sword
Posts: 652
Joined: Fri Nov 30, 2018 1:04 pm
Acorn CNC Controller: Yes
Plasma CNC Controller: No
AcornSix CNC Controller: No
Allin1DC CNC Controller: No
Hickory CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: none
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Thorp WI

Re: Show me your Custom VCP's!

Post by Sword »

I replied to your other post, but just another thought, do you happen to have OUT5 forced off/open?

https://centroidcncforum.com/viewtopic.php?f=60&t=7685
Scott
ShawnM
Posts: 2190
Joined: Fri May 24, 2019 8:34 am
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 7804734C6498-0401191832
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Clearwater, FL

Re: Show me your Custom VCP's!

Post by ShawnM »

Chipwelder wrote: Sat Feb 04, 2023 11:27 pm What I am trying to do is turn my spindle on and off using one output and the two preprogramed red and green spindle on/off buttons.
This is exactly what the stock VCP does. Assign one output, any output you want, to “SpinFWD” in the wizard output page, wire the VFD per the numerous schematics and you can do exactly what you want. This will turn the spindle off and on using the red and green buttons in manual mode on the VCP and allow you to turn it off and on with M codes in MDI or g code.
Post Reply