Hello Guest it is April 20, 2024, 05:18:45 AM

Author Topic: Jogging/Pendant Interface-What is the best way? Ramblings  (Read 39758 times)

0 Members and 1 Guest are viewing this topic.

Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #80 on: June 10, 2015, 12:50:58 PM »
Your radio events are getting called, put a wx.wxMessageBox("my message"); under your event function.
when ever you change to that button (i.e. it was un-chechecked, now it is checked) the message will fire.
 
Your Paint events are being called in the Stand Alone, but..... they are not being called in the Panel version.........

But....... the "Jog" examples panels paint even DOES work.......... so........... go figure.........
Probably see if Steve can figure out why your paints are not firing.

Scott


fun times

Offline TimGS

*
  •  108 108
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #81 on: June 10, 2015, 01:11:46 PM »
I will try to put a wx.wxMessageBox("my message"); under myevent function tonight...just in case I have other problems.

If it is just a paint issue, that gets me closer; maybe take a closer look at the "jog" code to see if I made a mistake connecting to wx.wxEVT_PAINT.  I will also see about how to monitor the windows message handler, that might help.

Once working this code will open the door for some interesting screens ;D.

Thank You for your help!!!!!

Offline TimGS

*
  •  108 108
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #82 on: June 10, 2015, 07:02:04 PM »
I FOUND THE PROBLEM ;D ... stay tuned

Offline TimGS

*
  •  108 108
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #83 on: June 10, 2015, 07:27:46 PM »
This code works....
1) Add a LUA Panel
2) Add code to the script of the LUA Panel

Thank You Poppa Bear... I used the dialog to find where the code was failing.  I was so convinced that I wasn't receiving the events because I had put in a statement to watch for the button switching events.  What I did not know was that the statement " frame:SetStatusText("MPG OFF");"  was causing and error and the code would bail out right there and skip the change in the switch position and everything after that; restarting the loop when it hit the bottom of the code!  That statement works as long as there is a frame to report to.

Now I will add the controls to Mach4 Thank You



Offline poppabear

*
  • *
  •  2,235 2,235
  • Briceville, TN, USA
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #84 on: June 10, 2015, 08:54:01 PM »
Another trick you can do, especially if your wanting to watch more than one thing or message.
Pipe your data to a Register, and then use the diagnostics window which is live time, and you can
watch several at once.

Scott
fun times

Offline TimGS

*
  •  108 108
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #85 on: June 10, 2015, 09:02:10 PM »
I will have to learn how to do that soon ;D

Thank YOU!!!!
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #86 on: June 11, 2015, 05:52:00 AM »
Tim,

How'd you get it to stick to the panel IN mach4? I figured out the whole wizards application and standalone frames for wx.Widgets from examples in the toolbox (thanx poppabear). Care to help an understudy out?

Offline dude1

*
  •  1,253 1,253
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #87 on: June 11, 2015, 06:18:16 AM »
if you have a look at what poppabear did it will show you

Offline DazTheGas

*
  •  778 778
  • DazTheGas
    • View Profile
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #88 on: June 11, 2015, 06:23:57 AM »
Very impressive, found a bit in that code that has stumped me for a bit... Cheers

DazTheGas
New For 2022 - Instagram: dazthegas
Re: Jogging/Pendant Interface-What is the best way? Ramblings
« Reply #89 on: June 11, 2015, 06:29:18 AM »
Dude! are we blaming the democrats or the republicans? hehe

Hi Tim--
 I thing poppabear is referencing the read/write/save register functions and using the diagnostics register window to view "real time" updates. (so, I actually have the logging window open on play and the register diagnostics open. No kidding, m4 updates that sh17 FAST! I was impressed. That was how I know my script/function call was working.)
« Last Edit: June 11, 2015, 06:33:48 AM by Screwie Louie »