Generic Probing tab
31 Mar 2015 07:00 - 31 Mar 2015 07:02 #57327
by andypugh
Generic Probing tab was created by andypugh
I have had a bit of a play with this, and I think I have the basics.
There are two files, an svg of button logos and a python file to display the buttons and run G-code.
There are arguments for making each button a separate GladeVCP widget. There are other ways to do this, and there are _much_ better Python programmers.
What I do like is that the button graphics are scalable. I quite like that there are only two files. (and I can't help feeling that with clever XML it could be one file).
So, put gtktest.py and probe.svg in the same folder, then start LinuxCNC and then (in a terminal) ./gtktest.py
That should pop-up a window with 4 buttons that do different things. They don't do any actual probing yet.
There are more options for the button-graphics in the svg fille.
To Do:
Put in the actual probing code.
Add the numeric inputs, checkboxes etc.
Make the graphics actually pretty.
This is so-far a proof of concept rather than a usable thing.
There are two files, an svg of button logos and a python file to display the buttons and run G-code.
There are arguments for making each button a separate GladeVCP widget. There are other ways to do this, and there are _much_ better Python programmers.
What I do like is that the button graphics are scalable. I quite like that there are only two files. (and I can't help feeling that with clever XML it could be one file).
So, put gtktest.py and probe.svg in the same folder, then start LinuxCNC and then (in a terminal) ./gtktest.py
That should pop-up a window with 4 buttons that do different things. They don't do any actual probing yet.
There are more options for the button-graphics in the svg fille.
To Do:
Put in the actual probing code.
Add the numeric inputs, checkboxes etc.
Make the graphics actually pretty.
This is so-far a proof of concept rather than a usable thing.
Last edit: 31 Mar 2015 07:02 by andypugh.
Please Log in or Create an account to join the conversation.
31 Mar 2015 07:49 #57331
by ssalrin
Replied by ssalrin on topic Generic Probing tab
I knew it! I wasn't planning on putting together a linux box, but it looks like I'll have to
I know nothing about this as of yet, but I do know when something is worth effort. I might be able to help with graphic, if Adobe CS4 will suffice.
I know nothing about this as of yet, but I do know when something is worth effort. I might be able to help with graphic, if Adobe CS4 will suffice.
Please Log in or Create an account to join the conversation.
31 Mar 2015 08:03 #57334
by andypugh
Well, it depends..
Photoshop won't work, as the graphics are Vector. Illustrator would be the tool, but there would almost certainly have to be some hand-editing of the SVG afterwards to force it in to the format that the python script assumes.
If you compare the probe.svg and what the same file looks like after passing through Illustrator (in a text editor) then you might see what I mean. Inkscape created a separate gradient for every arrow-fill, for example, so I deleted all but one and did a search-replace.
This may be a perspective thing. I had a sideline in computer graphics when I was at school, but all the graphics were created by BASIC plot commands. I am amazed I had the patience.
It was probably 30 lines of code to sign the picture (and rather embarassingly the interweb now thinks I wrote the game) s.uvlist.net/l/y2006/05/18345.jpg
So, hand-crafting SVG feels sensible to me, but might not to others.
Replied by andypugh on topic Generic Probing tab
I might be able to help with graphic, if Adobe CS4 will suffice.
Well, it depends..
Photoshop won't work, as the graphics are Vector. Illustrator would be the tool, but there would almost certainly have to be some hand-editing of the SVG afterwards to force it in to the format that the python script assumes.
If you compare the probe.svg and what the same file looks like after passing through Illustrator (in a text editor) then you might see what I mean. Inkscape created a separate gradient for every arrow-fill, for example, so I deleted all but one and did a search-replace.
This may be a perspective thing. I had a sideline in computer graphics when I was at school, but all the graphics were created by BASIC plot commands. I am amazed I had the patience.
It was probably 30 lines of code to sign the picture (and rather embarassingly the interweb now thinks I wrote the game) s.uvlist.net/l/y2006/05/18345.jpg
So, hand-crafting SVG feels sensible to me, but might not to others.
Please Log in or Create an account to join the conversation.
31 Mar 2015 09:23 #57338
by ssalrin
Replied by ssalrin on topic Generic Probing tab
Is there nothing simple in this brave new world I've stepped into.... I see a lot of the screen components I've looked at this week open in fireworks. I've not used it, but I have it. I also have CorelDraw, very old... 9 I think, but I guess I'll start by looking at SVG.
Please Log in or Create an account to join the conversation.
31 Mar 2015 16:33 #57343
by andypugh
It looks like Fireworks only saves to SVG with an extension. I would expect Illustrator to be the editor of choice. I used Inkscape (then saved as plain SVG, then tweaked with a text editor). But learning to use Inkscape if you are used to Adobe might be a waste.
Replied by andypugh on topic Generic Probing tab
Is there nothing simple in this brave new world I've stepped into.... I see a lot of the screen components I've looked at this week open in fireworks.
It looks like Fireworks only saves to SVG with an extension. I would expect Illustrator to be the editor of choice. I used Inkscape (then saved as plain SVG, then tweaked with a text editor). But learning to use Inkscape if you are used to Adobe might be a waste.
Please Log in or Create an account to join the conversation.
31 Mar 2015 20:19 #57345
by ssalrin
Replied by ssalrin on topic Generic Probing tab
I'm not used to Illustrator, I have it, for photoshop, but I've not been serious even with photoshop for 10+ years... I only still have it because of educational discounts. I'm looking at inkscape now. I remember this, it's come along way. Last time I saw this I had put linkux on an Xbox, making a file server...
Please Log in or Create an account to join the conversation.
31 Mar 2015 23:54 #57350
by BigJohnT
Replied by BigJohnT on topic Generic Probing tab
What is the rsvg module? I get an error trying to run it from Axis about the module missing.
JT
JT
Please Log in or Create an account to join the conversation.
01 Apr 2015 01:25 - 01 Apr 2015 01:25 #57352
by andypugh
Hmm, try apt-get install librsvg ?
Replied by andypugh on topic Generic Probing tab
What is the rsvg module?
Hmm, try apt-get install librsvg ?
Last edit: 01 Apr 2015 01:25 by andypugh.
Please Log in or Create an account to join the conversation.
01 Apr 2015 18:11 #57367
by newbynobi
Replied by newbynobi on topic Generic Probing tab
correct would be:
sudo apt-get install python-rsvg
at least for Ubuntu 10.04
Norbert
sudo apt-get install python-rsvg
at least for Ubuntu 10.04
Norbert
Please Log in or Create an account to join the conversation.
03 Apr 2015 07:33 #57463
by Quadro
Replied by Quadro on topic Generic Probing tab
Hello all,
Due to the all of the different types of machines that this would be used for, would it be best to call ngc file subroutines for each probe event instead of embedding it into the software.
Some like to probe twice, fast then again slow or only once.
I'm sure there are other ways to probe or options but if it is in the ngc file it can be edited by a competent operator, take away the screen clutter and make it 'universal'.
Maybe even a few extra user buttons for that special probe routine ie grid probe or what ever people have needs for.
Just a thought.
Anthony
Due to the all of the different types of machines that this would be used for, would it be best to call ngc file subroutines for each probe event instead of embedding it into the software.
Some like to probe twice, fast then again slow or only once.
I'm sure there are other ways to probe or options but if it is in the ngc file it can be edited by a competent operator, take away the screen clutter and make it 'universal'.
Maybe even a few extra user buttons for that special probe routine ie grid probe or what ever people have needs for.
Just a thought.
Anthony
Please Log in or Create an account to join the conversation.
Time to create page: 0.102 seconds