Several KMotionCNC Users have requested a method of having a C Program request an Operator Input Value so we have added this capability.
Within the C Program make a call to InputBox() - example below:
Executing this code will generate a Dialog Box within KMotionCNC and allow the Opertor to enter a value such as 123.456 (or Cancel):Code:#include "KMotionDef.h" #define TMP 10 // which spare persist to use to transfer data #include "KflopToKMotionCNCFunctions.c" main() { int Answer; float value; Answer = InputBox("Enter Distance",&value); if (Answer) printf("Operator Canceled\n"); else printf("Operator Entered Value of %.3f\n",value); }
With the result depending on the Operator input of:
To make use of this functionality add and patch the following files in Test Version V4.33c
http://dynomotion.com/Software/KMotion433cc.exe
Files are located here:
Index of /Software/Patch/AddValueInputKFLOP_KMotionCNCV433c
Copy KMotionCNC.exe to the KMotion/Release Directory
Copy PC-DSP.h to the DSP_KFLOP directory
Copy KflopToKMotionCNCFunctions.c to the C Programs Directory
Copy MessageInputBox.c to the C Programs Directory
Please provide feedback if problems are encountered.
Regards
Similar Threads:
Regards
TK http://dynomotion.com