Hello Guest it is May 12, 2021, 08:01:58 AM

Author Topic: more lua (?) questions  (Read 5411 times)

0 Members and 1 Guest are viewing this topic.

Re: more lua (?) questions
« Reply #20 on: May 03, 2017, 07:36:53 AM »
First of all: 3382 looks pretty good. Way smarter, than the both releases before :D

Related to my notebook-problem: I happened to note, that the first notebook-tab does the same, as the second. No other page shows this.
Could it be, that the first tabpage executes the script of the second page accidently?
Re: more lua (?) questions
« Reply #21 on: May 03, 2017, 09:54:09 AM »
Hello,

I tried to access the fixtures according the provided sample "Fixture Offset Table.mcs". The sample fails at GetID() where it accesses mc.FIXTURES_START
Looks like that constant is not defined. So what am I doing wrong?

Offline smurph

*
  • *
  •  1,401 1,401
  • "That there... that's an RV."
    • View Profile
Re: more lua (?) questions
« Reply #22 on: May 03, 2017, 09:15:24 PM »
Old example that hasn't been updated.  :(  Use mc.MC_FIXTURES_START and mc.SV_HEAD_SHIFT_(x) where (x) is the axis letter.

BTW, you can view these constants by viewing the LUA global table in the mcLuaEditor. 

Steve
Re: more lua (?) questions
« Reply #23 on: May 03, 2017, 11:08:20 PM »
Hi,

more important than the constant values is the knowledge about the array content.

I'm too stupid for the mcLuaEditor - the watchwindow doesn't work for me at all. At least it does not work like the watchwindows, I know from other devtools. I can enter a variable name, but the watch window does not show the content of the variable and I can't enter a new value ...
The only way to inspect a value is the flyover-tooltip, but I didn't find a way to modify the content of a variable (during debug session).
So I don't know, how to access the global table or any other value for inspection :(

... and I don't understand the difference in api: tooltable entries are pretty easy to access. The api is straight forward.
The fixtures access looks somewhat crappy/complex to me. So as if you would say: don't touch these items, they are my proprietary ...

Offline smurph

*
  • *
  •  1,401 1,401
  • "That there... that's an RV."
    • View Profile
Re: more lua (?) questions
« Reply #24 on: May 04, 2017, 12:02:40 AM »
The fixture tables are setup to be Fanuc compatible.  They are arranged in the system variable memory space in a specific order.  Over the years, they have added more fixture offsets with G54.1 Px, where x is 1 to 99.  So yes, it is complicated.  If you want to understand all of this stuff, have a look at a Fanuc 21i control manual. 

Most of our users are not interested in heavily modifying a screen.  They usually run a stock screen set with maybe a few mods.  Thus they are not getting into the nitty gritty like you are.  OEMs will usually design a screen to work with a specific machine and have worked with the screen editor and LUA enough to know how to get what they want.  And yes, LUA has a face only a mother could love.  But it is, as you stated, stupid fast.  In the end, that is why we chose it. 

Mach Industrial has tool tables and fixture tables built in the screen set as controls.  As well as round buttons and buttons that support transparencies.  Plus Macro B conditional G code and tool life management. 

Steve
Re: more lua (?) questions
« Reply #25 on: May 04, 2017, 12:22:44 AM »
I didn't imagine, that anybody can spent a dime in compatibility to fanuc =:O
In this part of the world, fanuc is synonym to evil :D
... and no - I don't want to read a fanuc manual.

Quote
Mach Industrial has ...
Hey, you're a good seller :D

But the fee is too much for me. If you're interested in help on a linux variant, we can talk about working together ...
Currently I can't work to get my cnc-machine ready, so I spend my time getting into mach ...
I'm nearly 60 years old and hobby should stay what it is ;)
I'm creating a new screen, cause I want to recognize the machine state from the other side of the room (5-6m) and my eyes became weak ...

I think you can imagine - that if you worked for many years for professional business only, your mind has changed toward professional. But that does not mean, that your budget has increased too ;)

Offline smurph

*
  • *
  •  1,401 1,401
  • "That there... that's an RV."
    • View Profile
Re: more lua (?) questions
« Reply #26 on: May 04, 2017, 12:56:28 AM »
Well...  like it or not, Fanuc has the market share.  You see it plain as day at IMTS.  :(  But I can write interpreters that will mimic anything.  (I have Okuma, Haas, Siemens, and Fidia manuals)  It is just that we don't have people asking for anything but Fanuc.  It is what people know. 

We would have to get a sale for 1000s of licenses in order for us to justify writing another interpreter though.  Maybe it will happen one day.

Mach 4 will run on Linux.  In fact, we ran Mach 4 on Linux when we introduced Mach 4 to the world at IMTS 2016.  However, since our existing customer base was on Windows, we have concentrated on that.  I'm hoping to get time to bring the Linux port up to speed soon.  But it will probably be available only to OEMs at first. 

Steve
Re: more lua (?) questions
« Reply #27 on: May 04, 2017, 01:19:15 AM »
Quote
It is just that we don't have people asking for anything but Fanuc.  It is what people know.
That's completely fine.
What I don't understand: why you let fanuc customers influence your mach internals like memory organisations.
I wrote lots of interpreters too and one thing is the syntax you have to process and a very other part is the internals of your applications memory.

... anyway - its your business and I don't wonna argue on your decisions :)

Can you explain me, what's the work shift and head shift? I understand the words, but I don't know the meaning in machining. Is it a lathe issue?
I don't know such things from milling.
When/where does those values come into play?

Can you fix the sample? There are a lot of unknown items I don't know how to find out on myself.

Quote
I'm hoping to get time to bring the Linux port up to speed soon.
So do I :D
If there ever is something I can do/help on that item, please let me know.
If OEM is related to nondisclosure, I'll sign anything needed - but if OEM is about making money, I'm not your man.

cheers Reinhard

Offline smurph

*
  • *
  •  1,401 1,401
  • "That there... that's an RV."
    • View Profile
Re: more lua (?) questions
« Reply #28 on: May 04, 2017, 01:51:05 AM »
Well... Fanuc Macro B code depends a lot on the internal memory locations.  Take probing, for example.  Renishaw has Macro B probing routines for their probes.  And those routines depend on those memory locations being where they think they will be.  To set offsets and such.  The probed locations are stored in #5061 to #5066  (X to Z user coordinates and #5071 to #5076 for the machine coordinates.  Also, subroutines can be written to look and see if there is an offset in effect and then do something special like interpolating a hole with the diameter being the same no matter what the cutter diameter is, etc...  It is actually quite an elegant system the more you study it.  But it is complex because it is a register file system that has been patched over the years. 

Work shift is a global offset that will affect all other offsets.  Head shift is an offset that can be used with dual spindle machines.  Neither of those is used with a convention 3 axis milling machine. 

The example is fixed and will be in the next build.

Mach Linux for the OEMs first, because they will have less support issues.  In the end, we will probably make a setup similar to the EMC Brain Dead Install before pushing it out to the masses and ONLY support it on the provided OS.  There are just too many "flavors" of Linux out there and I don't want to have to install and test on every one of them.  I'm a Linux fan.  I used to write UNIX operating systems and device drivers (Motorola 68K and 88K).  But Linux is an unholy mess of different distributions and everyone has their favorite. 

Steve
Re: more lua (?) questions
« Reply #29 on: May 04, 2017, 03:32:16 AM »
Quote
The probed locations are stored in #5061 to #5066  (X to Z user coordinates and #5071 to #5076 for the machine coordinates.
Afaik linuxcnc works the same way.

Quote
It is actually quite an elegant system the more you study it.
I didn't get deep into fanuc, but from what I know, I like the macro features. Quite nice.

Quote
The example is fixed and will be in the next build.
Thank you very much!

Quote
But Linux is an unholy mess of different distributions and everyone has their favorite.
poor conclusion but very true!
I worked with many os and tried many linux flavors - I guess it was 05 when I found the most stable flavor and I did not changed since then. No problems, even on major updates and the os let me do what I want and does not force me to do things, the os wants to be done ;)

What about licenses. Will a windows-license be valid on linux systems?
May be next week I'll get my smoothstepper, so that would be the time to think about buying a license.