-
Notifications
You must be signed in to change notification settings - Fork 1
Using the Module
chrilith edited this page Mar 13, 2016
·
6 revisions
If Passerelle has been installed properly, you should be able to enable its fonctionalities using:
require("passerelle");
print(passerelle.getNumDevices());
If you want to put it in another location, you should replace the 'require' with the following code:
local lib = package.loadlib("D:\\path\\\to\\passerelle.dll","luaopen_passerelle");
if (lib) then
lib();
else
print("error");
end
Prior to v0.7.0, a legacy version was provided in order to test the latest version of Passerelle and the compatibility script code was built-in the C module. Now a compatibility script is included in a separated file and can be used like this:
-- The module was previously called 'saitek', you must replace the 'require' call.
require("passerelle");
-- Execute the 'compat.lua' script
dofile("compat.lua");
When calling an obsolete methods, a trace is now added to the Lua execution console.