Hello Guest it is April 28, 2024, 07:38:27 PM

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - HimyKabibble

951
General Mach Discussion / New Mach3 v4 VB Interface
« on: October 16, 2009, 09:45:49 PM »
Below is the proposed set of VB functions to be supported in the first release of the Mach3 v4 VB interface, excluding Modbus and Serial.  Modbus will remain unchanged for now, and Serial support will be completely new, but is, as yet, undefined.

All you VB users, please review, and if you see any missing functionality, or have questions about what some of the functions do, or how, please let me know.  The interfaces have been "regularized", to make them more consistent, and in the hopes of making the functions more clear just from the names.  Redundancy has been eliminated, and arguments and return values are now also consistent.  So, for example, in the old interface, FeedRate returned the FeedRate in units/min, but SetFeedRate set the new FeedRate in units/second, the new GetFeedRate and SetFeedRate both operate in units/minute.  The "Is" functions now all return Booleans, rather than Integers.   Overall, it should be FAR easier to learn to write and debug Mach3 macros. 

There are also countless "invisible" changes that will eliminate some of the more frustrating aspects of Mach3 programming.  For example, it should normally *never* be necessary to insert wait loops or Sleeps in the code, as it currently is.  Execution will be far more deterministic, with far fewer hidden pitfalls.

Port/Signal I/O:
Sub AssertOutput(Signal As Integer)
Sub DeassertOutput(Signal As Integer)
Function IsInputAsserted(Signal As Integer)As Boolean
Function IsSignalDefined(Signal As Integer) As Boolean
Function IsOutputAsserted(Signal As Integer) As Boolean

File I/O:
Sub OpenDigFile()
Sub CloseDigFile()
Function OpenTeachFile (Filename As String) As Integer
Function AppendTeachFile(Filename As String) As Integer
Sub CloseTeachFile() As Integer
Sub LoadTeachFile() As Integer
Function GetFileName() As String
Function GetMach3Folder() As String
Sub LoadProgram(FilePath As String) As Integer
Sub LoadAndRunProgram(FilePath As String) As Integer
Sub RunProgram() As Integer
Sub LoadWizard(WizardName As String) As Integer

Screenset/UserI/O:
Function AskUserForDouble() As Double
Function AskUserForText() As String
Function AskUser(Prompt, “Title” As String, DialogType As Integer) As Integer
Sub ErrorMessage(MessageText As String)
Sub TickerMessage(TickerNum As Integer, TickerText As String)
Function AskUserForCoords(Prompt As String) As Integer
Function GetXCoord() As Double
Function GetYCoord() As Double
Function GetZCoord() As Double
Function GetACoord() As Double
Function GetBCoord() As Double
Function GetCCoord() As Double
Sub DoOEMButton(OEMButtonCode As Integer)
Function GetOEMLED(LEDNum As Integer) As Integer
Sub SetOEMDRO(DRONum As Integer, DROVal as Double)
Function GetOEMDRO(DRONum As Integer) As Double
Sub SetUserLED(LEDNum As Integer, State As Integer)
Function GetUserLED(LEDNum As Integer) As Integer
Sub SetUserDRO(DRONum As Integer, DROVal As Double)
Function GetUserDRO(DRONum As Integer) As Double
Sub SetVar(VarNum As Integer, Val As Double)
Function GetVar(VarNum As Integer) As Double
Sub SetUserLabel(LabelNum As Integer, LabelText As String)
Function GetUserLabel(LabelNum As Integer) As String
Sub SetButtonText(Text As String)
Function GetButtonText() As String
Sub SetScreensetPage()
Function GetScreensetPage() As Integer
Sub ToggleScreenset()
Sub ReloadScreenset()
Sub SetTriggerMacro(Signal As Integer, MacroName As String)

G-Code:
Sub SetBufferedCodeState(Boolean)
Function GetBufferedCodeState() As Boolean
Sub Code(Gcode As String)

Machine Control:
Sub SpindleOn(DIR)
Sub DoSpinCW()
Sub SpindleOff()
Sub SetRPM(RPM As Integer)
Function GetRPM() As Double
Function IsSpindleOn() As Boolean
Sub SetFeedRate(FeedRate As Double)
Function GetFeedRate() As Double
Sub Function CoupleSlave(MasterAxis As Integer, SlaveAxis As Integer)
Sub UncoupleSlave()
Function GetCurrentTool() As Integer
Sub SetIJIncremental(Boolean)
Function IsIJIncremental() As Boolean
Sub SetSafeZPos(SafeZ As Double)
Function GetSafeZPos() As Double
Sub GotoSafeZ()
Function IsSafeZEnabled() As Boolean
Sub SetAxisScale(Axis As Integer, Scale As Double)
Function GetAxisScale(Axis As Integer) As Double
Function GetSelectedTool() As Integer
Sub SetCurrentTool(ToolNum As Integer)
Function GetAxisToolChangeStartPos()
Function GetToolDesc(ToolNum As Integer) As String
Sub SetToolParam(ToolNum As Integer, ParamNum As Integer, ParamVal As Double)
Function GetToolParam(ToolNum As Integer, ParamNum As Integer)
Function ToolLengthOffset() As Double
Sub SetParam(ParamName As String, ParamVal As Double)
Function GetParam(ParamName As String) As Double
Function IsInEStop() As Boolean
Function IsProgramLoading() As Boolean
Function IsMoving() As Boolean
Function GetXMaxExtent() As Double
Function GetYMaxExtent() As Double
Function GetXMinExtent() As Double
Function GetYMinExtent() As Double
Sub WaitForTrigger(Signal As Integer)
Sub SwapAxis(FirstAxis As Integer, SecondAxis As Integer)
Sub UnSwapAxis()
Sub AxisJogOff(Axis As Integer)
Sub AxisJogOn(Axis As Integer, Dir as Integer)
Sub FeedMove(X, Y, Z, A, B, C As Double)
Sub RapidMove(X, Y, Z, A, B, C As Double)
Function SingleVerifyReport(Axis As Integer)
Sub SingleVerify(Axis As Integer)
Sub VerifyAxis(Silent As Boolean)
Sub RefCombination(Axes As Integer)
Sub THCOff()
Sub THCOn()
Sub ZeroTHC()
Sub ResetTHC()
Sub NotifyPlugins(Event As Integer)
Function QueueDepth() As Integer
Function CannedCycleRetractMode() As Integer
Sub SaveWizard() As Integer
Function SetAxisFormula(Axis As Integer, Formula As String) As Integer
Sub SetSpindlePulley(Pulley As Integer)

Lathe Only:
Function IsDiameterMode() As Boolean
Function GetToolTurretAng() As Double

VB/Misc:
Function PParameter() As Double
Function QParameter() As Double
Function RParameter() As Double
Sub PlayWave(Filename As String)
Sub Sleep(Time As Integer)
Sub Speak(TextToSpeak As String)
Function GetVBVersion() As String
Function GetMach3Version() As String

952
General Mach Discussion / Re: Gcode questions pt2
« on: October 16, 2009, 02:49:03 PM »
Thank you, I am sure that would be the same if it was x or y as the moving axis? I have never used a subprogram or am I sure how to set 1 up. I typically input into the MDI exactly what coorcinate I want to go to and it cuts that plane. I then subtract given amount and repeat. I have used a g code for probing but that is it really.

Something like this:

G90 (Set absolute mode)
G0 Z0.000
G98 P0001 L50 (Call subroutine O0001 50 times)
G0 Z1 (Pull Z clear)
M30 (Done)
O0001
G91 (Set incremental mode)
G1 Z-0.005 F5 (Step down 0.005 in Z)
G90 (Set absolute mode)
(Put G1 moves to cut your profile here)
G99 (Return)
M30

Regards,
Ray L.

953
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 16, 2009, 02:42:55 PM »
Thanks for that info Ray !
I understand moving to another machine, but what sort of "substantial changes to the hardware of the existing machine" would necessitate a reactivation ? Like changing the XML ? Or adding a 4th axis ?
RC


Substantial changes to the PC hardware, not the CNC machine.   Just like Windows.

Regards,
Ray L.

954
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 16, 2009, 01:21:38 PM »

Hello,
 I don't understand exactly what will be required here.
Following is a quote from Brian from this topic : http://www.machsupport.com/forum/index.php/topic,11068.0.html

Is this like a "one time activation" thing ? Or every time you start the machine ?   ? ??

Could someone please explain in detail  how this will be intended to work?

Doesn't look like a big deal to me buy maybe I'm not seeing it as it is.

Thanks,
RC



 
Quote
4.) License for Mach3 is about to be locked per machine ID.. The old
license format has served us well over the past 8 years but it is time
to change with the times   . This will be web based (you don't need to
have the controller computer connected to the web) . It is a simple code
that you need to type in... The license file that you have now will get
you into the data base and allow you to register your machines on the
web page to get your code. I hate to do this to you but we are getting
to many people copying license files and using us for support    . In
the end that is what pays to make it so we can keep working on the
software to make it better and more robust! one last note on the license
junk.. the terms will be the same.. If you are a hobby user (Not cutting
for money) you can run from the one license that you have BUT you will
need to register the machine on the web using the same license name..

Very much like Windows activation - When you do a new install, you'll have to get on the 'net and contact ArtSoft to get an "activation" key.  Once you have it, you're good to go, until you either move the software to a new machine, or make substantial changes to the hardware of the existing machine.  In either case, you go back to ArtSoft and get another activation key.  As I said, very much the way Windows activation works.  It should be quick and painless, and for 99.9% of people a one-time thing.

Regards,
Ray L.

955
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 15, 2009, 03:34:55 PM »
No way was I trying to create a nightmare for Brian about tools. I just figured that if it was "easy" (very loose) I would ask.

Ray, you are correct that 255 tools is more than enough tools. Unfortunately for me, and my wacky scheme, 1-255 is not an easily remembered format. See, my machine is a router and I use bits of all various configurations vs. just endmills and their variants. My post is configured to call out the tool by name as well as number so I can look at the code and see what is being requested. My issue is that (someday) I will forget to ensure that each "different" tool has a different number and that Mach will skip over the tool change.

My scheme (which is easy for me), just so it can be understood is as follows:

180 = .125" drill
182 = .125" endmill 2 FL
140 = .250" drill
142 = .250 endmill 2 FL
144 = .250 endmill 4FL
etc. etc.

Here is where I shoot myself in the foot:

901 = 90 degree V bit 1-inch
601 = 60 degree V bit 1 inch

and it can get worse for coves and ogees :)

Still not a big deal. Maybe one day, although I truly hate having to use one for reference, I will just create a spreadsheet and number everything 1-255 (I guess that is how most do it). The bottom line is Mach DOES (let me say again for all to hear DOES - DOES - DOES - DOES) work very well and I am not complaining in any shape or form.

Brian - Painless is good. Like I said, I am not worried about it (new activation scheme) until the day comes. I still like the idea of a dongle though :)

But are you using an auto toolchanger?  If not, just insert a comment into the code prior to each toolchange giving you the tool description, rather than the number.  That's what I do.  Numeric schemes always blow up at some point, because you have different tools that, per the scheme, would end up with the same number - straight-flute vs spiral flute, e.g..

Regards,
Ray L.

956
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 15, 2009, 12:30:36 PM »
And you will not publish this modifications, right?
So other users would benefit of more tools in Mach ;)

It is a good idea, for sure, but how do you ensure that Tool#3 is the 5mm-cutter THIS time?
If i understand you right, Tool#3 can be ANY tool every new job? You will have to look into the code-window to ensure, right?
What if the code-window is too small to see the whole name of the tool?

I would be happy to publish it, but I'm not terribly interested in explaining how it all works, as it is rather complex.  The code is all reasonably well written, but not really documented.  All of my tool descriptors are auto-generated by a Perl program, from information in an Excel spreadsheet.  This allows me to define feed/plunge rates, RPM, DOC, etc, algorithmically, rather than having to define them individually for every one of the hundreds of tools.  The Perl program generates a SheetCAM tool descriptor file.  I then have a custom SheetCAM POST that performs a number of functions, including the logical-to-physical mapping of tools and outputs a G-code file.  Finally, there is another Perl program that modified the G-code file by determining what pulley/motorspeed/VFD frequencies to use, so as to minimize the number of pulley and motor speed changes for the program as a while, then inserting M0s into the code, prompting for manual setting of the correct pulley, motor speed range for each tool, and many other things.  It's all HIGHLY customized to my machine, and my work flow.
As I said, I'd be happy to post it, but I'm not interested in "supporting" it.

Regards,
Ray L.

957
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 15, 2009, 11:23:48 AM »
And what CAM are you using? And what is the price of it?

I'm using SheetCAM TNG, with a VERY heavily customized POST, and a whole lotta Perl code to do most of the tool manipulation.

Regards,
Ray L.

958
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 14, 2009, 04:28:08 PM »
But it would be a very easy way to number the tools.
For example, you could number them this way:
1xx -> 1mm-cutter in any variation. For example 104 is a 1mm cutter with 4mm flute-length
2xx -> 2mm-cutter in any variation. For example 209 is a 2mm cutter with 9mm flute length
and so on.
There would be many possibilities for creating your own code for your toolsets.


And 255 tools may be enough if you only differ between the dia. and maybe rouging and smoothing-mills

But i'm using a router, a Lagun-mill and soon another router-like mill, and i'd like to use one tool-library for all machines.

There are THAT much cutter-types! I don't know the english meanings of the different types, so i write them in german:
Diamantverzahnt, Spiralverzahnt, Einschneider, Zweischneider, Dreischneider, Vierschneider, Fischschwanz, flach geschliffen, Radiusfräser, Kugelfräser and many, many more.
And all in different diameters, lengths, flute-lengths and so on... So i don't think that 255tools are that much?
I don't want to rework the tooltable every few days?


I hope you understand my english to some degree :)

I have hundreds of tools in my toolset, including one for every letter, number, and fractional drill, and multiple "logical" tools defined for each "physical" tool, so there's a separate logical tool defined for roughing, finishing, slotting, high-speed cutting, etc..  The CAM uses a very large library (hundreds of logical tools with numbers up to 1000 or more), but the POST re-numbers the tools on output, collapsing logical tools back down into physical tools, and doing it so any one job never has more than a handful of tools, always numbered sequentially starting at 1.  255 tools in Mach3 is more than plenty.

Regards,
Ray L.

959
General Mach Discussion / Re: Designing problem on Screen4.
« on: October 12, 2009, 10:48:31 AM »
Have you ever seen the following problem on Screen4?
Sometimes when saving the .set file and open it with mach3,
the whole screen has moved down usually about 100 pixels.
Sometimes more than the size of the screen!
Is that due to any mishandling of mine?
Or is that a bug?
Have you seen it?

Also, when designing a wizard, the bitmaps are not shown on screen4.
I have to move all files to mach3 folder to design it and then back to addons folder to see it with mach.
Any comments on this?

regards,
giannis


That is just one of the many, many bugs and annoyances in Scream4, which happens most often when you're editing a screen that is too large to display in Scream4 without scrolling.  Do yourself a favor, and download MachScreen.  It's about 100X more stable than Scream4.

Regards,
Ray L.

960
General Mach Discussion / Re: re: Whats happened to Mach.4 update
« on: October 11, 2009, 02:29:56 PM »
Hi Brian and Art
I have heard a lot about a mach 4 version with many of the bug's in Mach 3 fixed late last year around December a developer said he got a copy of it for beta testing recently he said there had been nothing further on it any info available is this as far as mach is going.

Rg's
Dennis

Brian has been working very hard on v4 for many months.  It will be a VERY different animal from v3, with many, many VERY significant changes (all very much for the better!).

Regards,
Ray L.