image as a button and jog wheel

More
14 Feb 2018 10:10 #105878 by Thomas
hello together,

at the moment I'm working again at my cnc-router and I'm just modifying my LinuxCNC Overlay.
You can see my screenshot in the attachments.

I don't know if this is possible with pyvcp or not, but I don't know how to make a image as a button. My solution for the moment are the buttons X+. X-, Y+, Y- next the images. I want to delete the buttons and want to press the images instead. How can I do that?

Second question is about my jogwheel. I don't know how to connect it. I don't have addons and if I run LinuxCNC, I'll get a error message like:
HAL: ERROR: function 'conv_float_s32.0' not found
custom_postgui.hal:23: addf failed

my 'custom_postgui.hal'

loadrt conv_float_s32 count=1
addf conv_float_s32.0 servo-thread
net jogwheel_float pyvcp.jog-wheel.output => conv_float_s32.0.in
net jogwheel_long conv_float_s32.0.out => axis.0.jog-counts axis.1.jog-counts axis.2.jog-counts
net jog_x axisgui.jog.x => axis.0.jog-enable
net jog_y axisgui.jog.y => axis.1.jog-enable
net jog_z axisgui.jog.z => axis.2.jog-enable


my 'custompanel.xml'

-<labelframe text="::: Jog Wheel :::">
<font>('Helevetia',10)</font>
<hbox>
<image_bit images="empty2"/>

<vbox>
<radiobutton>
<choices>["X","Y","Z"]</choices>
<halpin>"jog-axis"</halpin>
</radiobutton>

<radiobutton>
<choices>["OFF","0.100","0.010"]</choices>
<halpin>"jog-scale"</halpin>
</radiobutton>
</vbox>
<image_bit images="empty2"/>

<jogwheel>
<cpr>100</cpr>
<size>150</size>
<halpin>"jog-wheel"</halpin>
</jogwheel>
</hbox>
</labelframe>


The image_bit empty2 is only for optics, to get more distance between the widgets.

Thank you for your help and I'll hope I can realize my wishes without GVCP or other addons.

greetings Thomas
Attachments:

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

More
15 Feb 2018 21:48 #105994 by cmorley
pyVCP does not have an image button option - it would be a nice addition.

the ere comes from the fact that the conv_float_s32 component's name uses underscores but everything else related to it uses dashes.

addf conv-float-s32.0 servo-thread
net jogwheel_float pyvcp.jog-wheel.output => conv-float-s32.0.in

etc

Chris M
The following user(s) said Thank You: Thomas

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

More
16 Feb 2018 09:59 #106008 by Thomas
thank you Chris.

So I don't have to search anymore to find a solution. I decide to try this with glade, but have to learn and read a little bit more.

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

More
23 Feb 2020 16:18 #158306 by 3D-Master
this is what i want to do as well. Pressing Image buttons which will do something and the image itself, when pressed, will change to another image. Is it entirely not possible with Pyvcp or hasnt there been made a component for? Theoretically the "image bit" component could be copied and instead of the hal pin changing the images, a press of the image will result in the hal pin triggering something and changing the image itself.

Theoretically.

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

More
23 Feb 2020 16:54 #158310 by cmorley
It's not possible in pyvcp because no one has coded it.
Pyvcp doesn't get much development work because gladevcp was so much more capable.
Pyvcp code base is much more stable though.

Chris

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

Time to create page: 0.105 seconds
Powered by Kunena Forum