Page 1 of 1

Input trigger event - set my function

PostPosted: Thu Sep 22, 2016 6:10 am
by shad
Is it possible to add my function to the input trigger event? Or start my macros when the input trigger event issue?
For example I need to have fast handler for any input signal and then I need to make any action inside plugin (40 msec plugin loop is very big for this purpose).
Thank you!

Re: Input trigger event - set my function

PostPosted: Thu Sep 22, 2016 8:59 am
by cncdrive
If the 40msec is too long in the loop then you can create your own Thread in the plugin project.
The plugin project allows you to add anything which the C# language allows, so you can make your own thread which can be as fast as you want it to be.

In the input triggers if you set the function call between ID 20000 and 20999 those are macro call button codes, so if you assign these to input triggers or hotkeys then the macro will be called.

Re: Input trigger event - set my function

PostPosted: Fri Sep 23, 2016 7:05 am
by shad
Thank you!
Now I have 10.5 msec loop for communication to controller - 500 uSec for send/receive and 10 msec sleep.
And 40 msec plugin main loop for non time sensitive functions.
It's work great!