Lathe Macros

More
27 Aug 2016 22:10 - 27 Aug 2016 23:52 #79573 by OT-CNC
Replied by OT-CNC on topic Lathe Macros
Is there anyway I can display both the Cycles tab and have the Spindle rpm tab displayed on the right axis screen? I can get one or the other to display but not both.

EMBED_TAB_NAME = Cycles
EMBED_TAB_COMMAND = halcmd loadusr -Wn gladevcp gladevcp -c gladevcp -u lathehandler.py -x {XID} lathemacro.ui
#GLADEVCP = -H gvcp_call_list.hal gvcp-panel.ui

In gvcp_option.hal document I have:

# _DO NOT_ include your HAL commands here.
# Put custom HAL commands in custom_gvcp.hal

# **** Setup of spindle speed display using gladevcp ****

#net spindle-fb-rpm-abs-filtered => #gladevcp.spindle-speed
#net spindle-at-speed => gladevcp.spindle-at-#speed-led
# **** Setup GLADE MDI buttons ****
#net machine-is-on => gladevcp.button-box-active
Last edit: 27 Aug 2016 23:52 by OT-CNC.

Please Log in or Create an account to join the conversation.

More
28 Aug 2016 22:25 #79624 by andypugh
Replied by andypugh on topic Lathe Macros
You seem to have a lot of commented-out lines there. Perhaps that is why they don't work?

Please Log in or Create an account to join the conversation.

More
29 Aug 2016 00:03 #79630 by OT-CNC
Replied by OT-CNC on topic Lathe Macros
That is what I had to comment out to get cycles to display. If I don't comment out GLADEVCP = -H gvcp_call_list.hal gvcp-panel.ui and what's in the gvcp_option.hal then the cycles tab is embedded but doesn't show any of the contents.
How do I display both?

Please Log in or Create an account to join the conversation.

More
29 Aug 2016 14:26 #79655 by andypugh
Replied by andypugh on topic Lathe Macros

OT-CNC wrote: How do I display both?


I don't know for sure that you can. You could try changing the loading order of the things and making them wait for completion.

Or you could add the spindle speed display to each tab :-)

Please Log in or Create an account to join the conversation.

More
13 Nov 2016 18:30 - 13 Nov 2016 18:33 #82743 by andypugh
Replied by andypugh on topic Lathe Macros
As my new lathe has a touchscreen (and is using "Touchy" as the interface) I have re-worked my macro interface.


  • The graphical background is now re-sizable and stored in an SVG (in fact each image is stored in a different layer in the same .SVG)
  • Because Touchy always shows the DRO I have removed the DRO from the embedded tabs.
  • Touchy uses a physical cycle-start button, so I have added a HAL pin to the embedded tabs and hidden the buttons on the tabs (the action buttons are still where the G-code calls are stored, the physical button is made to emit a click event). If anyone wants the touch-buttons then it should only be a case of making the buttons visible. This might mean adding a parent window such as an event box.
  • Number-entry is now via a pop-up keyboard. I made a custom one to keep the option to type inch fractions (typing 1.3/4 will give 1.750)

  • Attachments:
    Last edit: 13 Nov 2016 18:33 by andypugh.

    Please Log in or Create an account to join the conversation.

    More
    13 Nov 2016 19:12 #82745 by BruceLayne
    Replied by BruceLayne on topic Lathe Macros
    That looks great, Andy. I'd love to see a live demo on YouTube showing how it all works together. I've been avoiding Touchy as less standard than Axis, but I might need to give this a try.

    Please Log in or Create an account to join the conversation.

    More
    13 Nov 2016 19:16 #82746 by andypugh
    Replied by andypugh on topic Lathe Macros
    There is a demo of the Axis version here:



    The Touchy version basically works the same way

    Please Log in or Create an account to join the conversation.

    More
    07 Dec 2016 06:40 #83728 by ZincBoy
    Replied by ZincBoy on topic Lathe Macros
    This looks to be exactly what I am looking for on my lathe. I am using gmoccapy though and when I install the touch version there are no svg graphics visible on the tabs. I see the settings values in the right places but no graphics. The numeric entry pop-up also doesn't show up when I tap on one of the values.

    For my .ini file, I needed the following:
    EMBED_TAB_NAME = Cycles
    EMBED_TAB_LOCATION = ntb_user_tabs
    EMBED_TAB_COMMAND = halcmd loadusr -Wn gladevcp gladevcp -c gladevcp -u lathehandler.py -x {XID} lathemacro.ui

    I have to specify the EMBED_TAB_LOCATION or the tab will not show up.

    The non-touch version seems to work but I was hoping to get the touch one running. Any suggestions would be greatly appreciated.

    Please Log in or Create an account to join the conversation.

    More
    07 Dec 2016 08:30 - 07 Dec 2016 08:32 #83733 by newbynobi
    Replied by newbynobi on topic Lathe Macros
    sudo apt-get install python-rsvg

    solved the problem of the grafics to me.

    But I have no play button any more!

    And If I enter a speed value of 350 I got 200 in the entry, similar in other entries, entering a value of 100 gives 3.000 etc.
    May be a inch metric behavior. I am using SI units so I am in metric!

    Attached my sim INI folder for gmoccapy.

    Norbert

    P.S. Andy the readme seems to be out of date.
    Attachments:
    Last edit: 07 Dec 2016 08:32 by newbynobi.
    The following user(s) said Thank You: ZincBoy, rishrsoni

    Please Log in or Create an account to join the conversation.

    More
    07 Dec 2016 09:53 #83735 by andypugh
    Replied by andypugh on topic Lathe Macros

    newbynobi wrote: But I have no play button any more!

    I deliberately removed that for Touchy because Touchy uses a physical button for cycle-start.

    Which reminds me, I added a feature to Touchy to make this work, and I forgot to investigate doing the same thing in Gmoccapy:
    git.linuxcnc.org/gitweb?p=linuxcnc.git;a...b3ae236486cb45cd0e9e

    The "Play" buttons are still there, and can be made visible by editing the .ui file (probably with a text-editor rather than risking Glade messing up the formatting). I think searching for the string "Action" will find them.

    And If I enter a speed value of 350 I got 200 in the entry, similar in other entries, entering a value of 100 gives 3.000 etc.
    May be a inch metric behavior. I am using SI units so I am in metric!


    No, I always work in metric too, so it isn't that. You might need to change the upper limits of the "adjustments" of the spinboxes.
    But: 350m/min is a very high surface speed, I don't think I ever go above 120.

    After some use I have noticed that the fact that the entry-widget initialises with the old value is very annoying, and I need to change that.

    Please Log in or Create an account to join the conversation.

    Time to create page: 0.144 seconds
    Powered by Kunena Forum