Machsupport Forum

Mach Discussion => Mach4 General Discussion => Topic started by: Analias on July 19, 2014, 06:15:14 PM

Title: Third-Party Lua Module Support?
Post by: Analias on July 19, 2014, 06:15:14 PM
If I want to encapsulate my code for supporting a screen set or to provide general functionality, where is the best place to drop it in the installation?

Will a simple require work?  I tried doing this for the PLC code and got an error.  If we want our own module support in the PLC script where's the best place to do the import of our modules?


-Freeman
Title: Re: Third-Party Lua Module Support?
Post by: poppabear on July 20, 2014, 12:28:06 AM
Freeman, look at the RC ciode, and DSC code I put in the tool box, they can both be integrated with screens or macros or what ever, in a module format. To "Hide" you code, have your require run your code as compiled. (see DSC 3.0) and you will get the idea, you can put the code where ever you like just make a path to it....  and have your installer to drop it there as well.

Scott