Home
Downloads
Mach3
Plugins
CAM Post Processors
Screensets
Purchase
Support
Forum
Tutorial Videos
Documentation
Yahoo Group
Mach Wiki
Resources
Contact Us
Links
CNCZone
German Forum
Italian Forum
Korean Forum
Portugese (Brazil) Forum
Russian Forum (RSK CNCROUTER)
Thai Forum
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
May 28, 2012, 08:55:46 AM
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
Search:
Advanced search
Select from and to languages
Chinese-simp to English
Chinese-trad to English
English to Chinese-simp
English to Chinese-trad
English to Dutch
English to French
English to German
English to Greek
English to Italian
English to Japanese
English to Korean
English to Portuguese
English to Russian
English to Spanish
Dutch to English
Dutch to French
French to English
French to German
French to Greek
French to Italian
French to Portuguese
French to Dutch
French to Spanish
German to English
German to French
Greek to English
Greek to French
Italian to English
Italian to French
Japanese to English
Korean to English
Portuguese to English
Portuguese to French
Russian to English
Spanish to English
Spanish to French
Machsupport Forum
Mach Discussion
VB and the development of wizards
Feed rate override switch
Pages:
1
Go Down
« previous
next »
Author
Topic: Feed rate override switch (Read 558 times)
0 Members and 2 Guests are viewing this topic.
Aeroshade
Active Member
Offline
Posts: 138
Feed rate override switch
«
on:
October 26, 2011, 11:35:27 AM »
Hello all, I have searched for an answer to this for awhile and have come up empty.
I have posted this in Brains and VB to get both opinions.
I have a 16 position binary switch ( 4 pins - 1,2,4,8). I have the pins set to Input #1,2,3 and 4. The way this switch works is pin 1 = 1, pin 2 = 2, pin 1 and pin 2 = 3 and so on tell you get 16 (counting all pins off as a position).
I need to find a way to have this control my feedrate over ride, plus my rapid override at the same time. I'm not sure if the best way would be with a Brain or in VB - Macropump. The most important thing is that the switch works fast.
I don't have a problem writing it up in my Macropump, just need a little guidance on the code.
This is what I was think for the layout, just not sure about the DRO for the FRO:
If IsActive(INPUT1) = False And
IsActive(INPUT2) = False And
IsActive(INPUT3) = False
IsActive(INPUT4) = False Then
SetOEMDRO(0, 0) <--- Needs to set the DRO to 0%
End If
If IsActive(INPUT1) And
IsActive(INPUT2) = False And
IsActive(INPUT3) = False
IsActive(INPUT4) = False Then
SetOEMDRO(0, 0) <--- Needs to set the DRO to 10%
End If
So on and so forth, tell I get all 16 positions set.
Any help would be GREAT!!
Thanks,
Aero
Logged
BR549
Active Member
Offline
Posts: 2,557
Re: Feed rate override switch
«
Reply #1 on:
October 26, 2011, 11:46:28 AM »
FOr that I would do it in the Brains. The Brians are much faster in the actual code side. AND seeing as it is a basic ladder type coding it would work best.
Now the brains CAN be painfull to build long ladders. IF you mess up somewhere you have to start all over from scratch to rebuild the Rungs of the ladder.
Just a thought, (;-) TP
Logged
Aeroshade
Active Member
Offline
Posts: 138
Re: Feed rate override switch
«
Reply #2 on:
October 26, 2011, 11:46:53 AM »
I could prob. do something like this:
CurrentFeedrate = FeedRate()
If IsActive(INPUT1) = False And
IsActive(INPUT2) = False And
IsActive(INPUT3) = False
IsActive(INPUT4) = False Then
CurrentFeedrate= 0
SetFeedrate(CurrentFeedrate)
End If
If IsActive(INPUT1) And
IsActive(INPUT2) = False And
IsActive(INPUT3) = False
IsActive(INPUT4) = False Then
CurrentFeedrate= CurrentFeedrate/10
SetFeedrate(CurrentFeedrate)
End If
And so on, not sure if the language is correct, but you get my point.
Logged
Aeroshade
Active Member
Offline
Posts: 138
Re: Feed rate override switch
«
Reply #3 on:
October 26, 2011, 11:48:29 AM »
Quote from: BR549 on October 26, 2011, 11:46:28 AM
FOr that I would do it in the Brains. The Brians are much faster in the actual code side. AND seeing as it is a basic ladder type coding it would work best.
Now the brains CAN be painfull to build long ladders. IF you mess up somewhere you have to start all over from scratch to rebuild the Rungs of the ladder.
Just a thought, (;-) TP
That is what i have been running into, what DRO would I need to change and how do I set its value? I have wrote VERY simple Brains, but I'm up to the challenge if it works good
ADD: I have never wrote a Brain were I had to set a value.
Logged
Aeroshade
Active Member
Offline
Posts: 138
Re: Feed rate override switch
«
Reply #4 on:
October 27, 2011, 11:40:14 AM »
If some one could write a simple one for reference that would be great, and I would much appreciate it.
Thanks
Aero
Logged
Overloaded
Global Moderator
Offline
Posts: 3,073
Re: Feed rate override switch
«
Reply #5 on:
October 27, 2011, 12:19:27 PM »
http://www.machsupport.com/forum/index.php/topic,6631.0.html
Russ
Logged
"I haven't failed. I've just found 10,000 ways that won't work." Edison
"You cannot help men permanently by doing for them what they could and should do for themselves."
Abe Lincoln
Aeroshade
Active Member
Offline
Posts: 138
Re: Feed rate override switch
«
Reply #6 on:
October 27, 2011, 01:16:16 PM »
I'm trying to get the Brain up and running. I have attached the Brain I'm messing with, but when I run it, it sets the FRO to the last % on the list (in this Brain it's 30%) and when I turn the switch the FRO doesn't change. Any ideas?
For the Macropump I tried this but I don't see any change:
If IsActive(INPUT1) = False And IsActive(INPUT2) = False And IsActive(INPUT3) = False And IsActive(INPUT4) = False Then
SetOEMDRO(821, 0)
End If
Thanks for the help
Aero
Feed Rate.brn
(10.46 KB - downloaded 15 times.)
Logged
BR549
Active Member
Offline
Posts: 2,557
Re: Feed rate override switch
«
Reply #7 on:
October 27, 2011, 01:41:56 PM »
Try something along these lines.
IF not IsActive(Input1) and not IsActive(Input2)and not IsActive(Input3) then SetOemDro(29,0.000)
(;-) TP
Logged
poppabear
S S SYSTEMS, LLC
Global Moderator
Offline
Posts: 1,707
Briceville, TN, USA
Re: Feed rate override switch
«
Reply #8 on:
November 03, 2011, 07:42:42 AM »
'MacroPump.m1s
'Here is another option using the Macro-Pump, since you have a potiential of 16
'positions. Figure out the numeric value of each combination in decimal.
'NOTE!! test and MAKE sure on the diagnostics page, that you are reading
'these 4 INPUTS when the B-switch makes them active!!!
BIT1 = IsActive(INPUT1) 'value in decimal of 0 or 1
BIT2 = IsActive(INPUT2) 'value in decimal of 0 or 2
BIT3 = IsActive(INPUT3) 'value in decimal of 0 or 4
BIT4 = IsActive(INPUT4) 'value in decimal of 0 or 8
DecimalValue = ( (BIT4 * 8) + (BIT3 * 4) + (BIT2 * 2) + (BIT1 * 1) )
If ( DecimalValue = 0 ) Then 'Four bit binary value expressed as decimal
SetOEMDRO(821, 0) 'FROVR DRO
End If
If ( DecimalValue = 1 ) Then 'Four bit binary value expressed as decimal
SetOEMDRO(821, 10) 'FROVR DRO
End If
If ( DecimalValue = 2 ) Then 'Four bit binary value expressed as decimal
SetOEMDRO(821, 20) 'FROVR DRO
End If
'ETC..........
'enjoy Scott
Logged
Commercial Mach3: Screens (regular and flash), Wizards, Plug-ins, Brains, PLCs, Macros, ATC's, machine build, retrofit and Prototyping
http://sites.google.com/site/volunteerfablab/
Pages:
1
Go Up
« previous
next »
Jump to:
Please select a destination:
-----------------------------
Mach Discussion
-----------------------------
=> General Mach Discussion
=> Mach3 under Vista
=> Quantum
=> Mach SDK plugin questions and answers.
===> Finished Plugins for Download
=> VB and the development of wizards
=> Brains Development
=> Video P*r*o*b*i*n*g
=> Mach Screens
===> Screen designer tips and tutorials
===> Works in progress
===> Finished Screens
===> Flash Screens
===> JetCam screen designer
===> Machscreen Screen Designer
===> CVI MachStdMill (MSM)
=> Feature Requests
=> Non English Forums
===> Italian
===> French
===> Spanish
===> Chinese
===> German
===> Russian
===> Romanian
===> Japanese
===> Vietnamese
=> FAQs
-----------------------------
*****VIDEOS*****
-----------------------------
=> *****VIDEOS*****
-----------------------------
General CNC Chat
-----------------------------
=> Share Your GCode
=> Show"N"Tell ( What you have made with your CNC machine.)
=> Building or Buying a Wood routing table.. Beginnners guide..
=> Show"N"Tell ( Your Machines)
-----------------------------
G-Code, CAD, and CAM
-----------------------------
=> G-Code, CAD, and CAM discussions
=> LazyCam (Beta)
-----------------------------
Third party software and hardware support forums.
-----------------------------
=> LazyTurn
=> GearoticMotion Preliminary testing
=> Tempest Trajectory Planner
=> Contec
=> dspMC/IP Motion Controller
=> HiCON Motion Controller
=> Third party software and hardware support forums.
=> Galil
=> Newfangled Solutions Wizards
=> Mach3 and G-Rex
=> Mesa
=> Modbus
=> NC Pod
=> PoKeys
=> SmoothStepper USB
=> Sieg Machines
=> Promote and discuss your product
-----------------------------
Tangent Corner
-----------------------------
=> Tangent Corner
=> Competitions
=> Polls
=> Bargain Basement
-----------------------------
Support
-----------------------------
=> Downloads
===> XML files
===> Post Processors
===> Macros
===> Tutorials
===> Others
===> Beta Brains
===> Screen Sets
===> Documents
===> MACH TOOL BOX
=> One on one phone support.
=> Forum suggestions and report forum problems.
-----------------------------
Mach4
-----------------------------
=> Mach4 pre-Alpha Testing
Loading...