Jump to content
The simFlight Network Forums

Recommended Posts

Posted

Hi all,

 

I refer to this post a few years ago.

 

https://forum.simflight.com/topic/70239-can-an-axis-change-its-function-depending-on-a-button-state/?tab=comments#comment-435414

 

I got this working a long time ago in P3D v3. I tried to get it working now in v4 with the A330. I want to assign one axis to the elevator and when on ground to the tiller. I used the multiaxis funtion to change the axis on a button press. Unfortunately it is not working. I used the "Controls List for P3D4 Build 32097.txt" file in the documents folder to find the elevator and tiller axis (throttle 3 axis for the aerosoft airbus) but the axis are not working.

 

If anybody could help me with that I would be very thankful ;-)

 

Best regards

 

Nicolas

Posted

Hi Nicolas,

1 hour ago, nicolas83 said:

Unfortunately it is not working

what exactly is the problem? Just telling us that it is not working is not very helpful. How are you trying to achieve this - via lua scripts? If so, have you tried log/debugging them?

Please provide more details and also attach your files (lua, ini, log).

Thanks,

John

 

Posted

Hi John. Thanks for your reply. I used exactly the method described in the post mentioned above. When I assign an axis to the offset dword set command as described the axis does not move in P3D then. I will provide Log, ini and lua in the evening. 

Posted
2 hours ago, nicolas83 said:

Just tried it with a default aircraft but its also not working. Log, ini and lua are attached.

Well, if you'd have looked in the log, which is where errors would be listed, you would have surely immediatelt seen:

37797 *** LUA Error: F:\P3D\Modules\multiaxis.lua:7: unexpected symbol near '/'
 
Look at the Lua file:

function applyaxis(val)
   cntrl = ipc.readUD(0x66c0)
   ipc.control(cntrl,val)
end

event.param("applyaxis")
[/CODE]

Line 7 is the [/CODE] line. That is NOT a Lua statement. It is evidently the end of a "code" section which you get when using the <> bracketing method (see editing options above). For example, to do this

function applyaxis(val)
   cntrl = ipc.readUD(0x66c0)
   ipc.control(cntrl,val)
end

event.param("applyaxis")
[/CODE]

Please do always look at Log files yourself, and ALWAYS check anything you extract from messages. Don't take things blindly.

Pete

 

  • 1 year later...
Posted
1 minute ago, nicolas83 said:

is it possible to use the multiaxis.lua in the new MSFS?

I don't know that script (where can I find it?) - best to just try it. Its probably fine, as long as whatever controls its using are available in MSFS.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use. Guidelines Privacy Policy We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.