All things related to the Centroid Acorn CNC Controller
Moderator: cnckeith
suntravel
Community Expert
Posts: 3640 Joined: Thu Sep 23, 2021 3:49 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 6433DB0446C1-08115074
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Germany
Post
by suntravel » Wed Jun 22, 2022 3:27 pm
Played with macros....
Made an M55 macro to calculate Vfc for circular pockets or internal thread milling, for the case I can´t find my calculator
Replaced code with a correct calculating version and logic for senseless user input
Code: Select all
;------------------------------------------------------------------------------
; Filename: mfunc55.mac - To run from VCP AUX 10 key, set p197 = 5511
; M55 macro
; Description: Calculate Vfc for internal thread milling or circ. pockets
; Requires: Machine home must be set prior to use.
; 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
#105=0
N100
M224 #101 "Calculate Vfc for\nint. thread milling\nor circ. pockets\n\nMill Diameter"
M224 #102 "Bore Diameter"
IF #101 >= #102 and #105 == 0 THEN GOTO 900 ELSE GOTO 110
N110
IF #101 >= #102 and #105 >= 1 THEN GOTO 990 ELSE GOTO 200
N200
M224 #104 "Feedrate Vf"
#103=#104/((#102*3.14)/((#102-#101)*3.14))
M225 #100 "Use for:\nMill Diameter: %f mm\nBore Diameter: %f mm\nFeedrate Vf: %f mm/min\n\nCalculated Feedrate\nVfc= %f mm/min" #101#102#104#103
GOTO 1000
N900
M225 #100 "Mill Diameter = %f\n can not be equal or larger then\nBore Diameter = %f\n\n Back to Start" #101#102
#105=1
GOTO 100
N990
M225 #100 "Really?\nThis will also not fit\n\nMill Diameter = %f\n can not be equal or larger then\nBore Diameter = %f\n\n Back to Start you Stupid" #101#102
GOTO 100
N1000 ;End of Macro
Attachments
mfunc55.mac
(1.36 KiB) Downloaded 23 times
Last edited by
suntravel on Thu Jun 23, 2022 10:24 am, edited 3 times in total.
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
johnballard
Posts: 32 Joined: Wed Feb 19, 2020 11:49 am
Acorn CNC Controller: No
Allin1DC CNC Controller: Yes
Oak CNC controller: No
CNC Control System Serial Number: 0818141095
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Post
by johnballard » Wed Jun 22, 2022 8:43 pm
Humm... in your VCP I see buttons I do not have. The 45's between the X & Y jog buttons and the Axis 0 and All zero. How does the axis 0 work.
Can you share the code for them? Does the code have to be compiled into the PLC program? Do the macros also work on the real CP (aux1, aux2, etc)?
Lagunmatic 250
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
rk9268vc
Posts: 267 Joined: Fri Nov 13, 2020 4: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
Post
by rk9268vc » Wed Jun 22, 2022 9:18 pm
johnballard wrote: ↑ Wed Jun 22, 2022 8:43 pm
Humm... in your VCP I see buttons I do not have. The 45's between the X & Y jog buttons and the Axis 0 and All zero.
He posted about it here
https://centroidcncforum.com/viewtopic.php?f=60&t=7356
and maybe in another thread as well, but cant find it
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
suntravel
Community Expert
Posts: 3640 Joined: Thu Sep 23, 2021 3:49 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 6433DB0446C1-08115074
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Germany
Post
by suntravel » Wed Jun 22, 2022 11:09 pm
The new buttons are in Acorn 4.79 Beta3.
Available as public download, give it a try, lots of good improvements in there
Uwe
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
suntravel
Community Expert
Posts: 3640 Joined: Thu Sep 23, 2021 3:49 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 6433DB0446C1-08115074
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Germany
Post
by suntravel » Thu Jun 23, 2022 8:35 am
Message for first and second wrong input in a row
Uwe
Attachments
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
suntravel
Community Expert
Posts: 3640 Joined: Thu Sep 23, 2021 3:49 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 6433DB0446C1-08115074
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Germany
Post
by suntravel » Thu Jun 23, 2022 10:26 am
Next two calculators and custom VCP
Quite a good training to make such things....
Uwe
Attachments
mfunc57.mac
(780 Bytes) Downloaded 42 times
mfunc56.mac
(819 Bytes) Downloaded 33 times
mfunc55.mac
(1.36 KiB) Downloaded 33 times
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
cnckeith
Site Admin
Posts: 8942 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:
Post
by cnckeith » Fri Jun 24, 2022 9:30 am
cool! thanks for posting.
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
ShaAli
Posts: 41 Joined: Mon Nov 21, 2022 12:51 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
Post
by ShaAli » Sat Feb 11, 2023 6:19 pm
Hello, sorry for a dump question, how do I change to macro to be in inches?
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
ShaAli
Posts: 41 Joined: Mon Nov 21, 2022 12:51 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
Post
by ShaAli » Sat Feb 11, 2023 6:23 pm
mm\nBore Diameter:
change them to in ?
in\nBore Diameter:
(Note: Liking will "up vote" a post in the search results helping others find good information faster)
suntravel
Community Expert
Posts: 3640 Joined: Thu Sep 23, 2021 3:49 pm
Acorn CNC Controller: Yes
Allin1DC CNC Controller: No
Oak CNC controller: No
CNC Control System Serial Number: 6433DB0446C1-08115074
DC3IOB: No
CNC12: Yes
CNC11: No
CPU10 or CPU7: No
Location: Germany
Post
by suntravel » Sun Feb 12, 2023 2:27 am
You can edit the macros to your liking.
Uwe
(Note: Liking will "up vote" a post in the search results helping others find good information faster)