Results 1 to 5 of 5
Thread: sim-avionics and SIOC
-
10-07-2009, 03:59 AM #1
- Join Date
- Aug 2009
- Location
- Netherlands
- Posts
- 18
sim-avionics and SIOC
Hello,
I am working on my cockpit and have a mastercard from opencockpits with sim-avionics suite.
Now I have a SIOC script to change the AP-heading with a rotary switch.
It works well on the FSX-screen (I can see the bug moving when I turn it on my flight-sim virtual cockpit) but on my screen of Sim-avionics it does not change.
What am I doing wrong?
Thanks
Steef
-
10-07-2009, 05:43 AM #2
- Join Date
- Jul 2013
- Posts
- 917
Re: sim-avionics and SIOC
Steef
How are you accessing the SA suite with SIOC? Are you using the multi-offset or have you defined an offset within the SA FSUIPC_IO.INI file. If so, which one are you using. Also perhaps you should post your SIOC text file.
Regards
David
-
10-07-2009, 06:07 AM #3
- Join Date
- Aug 2009
- Location
- Netherlands
- Posts
- 18
Re: sim-avionics and SIOC
Hi David,
Thanks for the quick response.
I am new to SIOC so, maybe I am doing something very wrong....
My txt file is (only for the heading yet):
Code:Var 1, name X_HDG, Link FSUIPC_INOUT, Offset $07CC, Length 2 { // convert from fsuipc range to degrees: L0 = DIV &X_HDG, 182 IF &HDG != L0 { &HDG = L0 } } Var 0055, Link FSUIPC_INOUT, Offset $53A2, Length 2 // HDG Var 2, name HDG { CALL &OutHDG } Var 3, name OutHDG, Link SUBRUTINE { // convert from degrees to fsuipc range: L0 = &HDG * 182 IF &X_HDG != L0 { &X_HDG = L0 } } Var 4, name RO_HDG, Link IOCARD_ENCODER, Input 3, Aceleration 4 Type 2 { L0 = &RO_HDG // * -1 turning right should be plus V0055 = ROTATE 0, 359, L0 &HDG = ROTATE 0, 359, L0 }
Thanks,
Steef
-
10-07-2009, 09:14 AM #4
- Join Date
- Jul 2013
- Posts
- 917
Re: sim-avionics and SIOC
Steef
I assume that your SIOC code and Hardware are working ok? Have you run the IOCPCONSOLE, this is an option within the SIOC screen to check that your encoder is being recognised and the values are being sent to FSUIPC.
Assuming all is ok, then have you set up the SA Server screen to receive FSUIPC INPUTS/OUTPUTS as per the manual ie within the Server screen/control panel option check the Use INPUTS and OUTPUTS boxes
Assuming all is ok again, then I suggest you try this SIOC code and make certain that the FSUIPC_IO.INI is edited to reflect the following entries.
SIOC Code
Var 0000, Value 0
{
&DIS_HDG = &HDG_OUT // HDG VALUE
}
Var 0005, Name HDG_OUT, Link FSUIPC_OUT, Offset $5302, Length 2 // HDG
Var 0064, Name ENC_HDG, Link IOCARD_ENCODER, Input 6, Aceleration 1, Type 2 // Encoder HDG
{
L0 = &ENC_HDG * -1
&DIS_HDG = ROTATE 0 ,360 ,L0
}
Var 0069, Name DIS_HDG, Link IOCARD_DISPLAY, Digit 6, Numbers 3 // DISPLAY HEADING
{
&HDG_OUT = &DIS_HDG
}
My entries for the encoder type and Input no will need to be changed to suit your system. Also make certain that the following entries are in your FSUIPC_IO.INI file
// INPUTS
// 2 byte (word)
MCP_HDG=5302
// Use FS formating
// HDG = value *65536/360
MCP_HDG_FS_FORMAT=0
Good luck
David
-
Post Thanks / Like - 1 Thanks, 0 Likes, 0 Dislikessboons thanked for this post
-
10-07-2009, 09:54 AM #5
- Join Date
- Aug 2009
- Location
- Netherlands
- Posts
- 18
Re: sim-avionics and SIOC
Hi David,
I have the light version of Sim-Avionics. I think this is the problem; the light doesn't have input/output support.
I will contact SA about this, THANKS for your help!
Similar Threads
-
Sim-Avionics
By Jason Dell in forum General Builder Questions All Aircraft TypesReplies: 7Last Post: 08-13-2009, 10:47 AM -
SIOC Code for Sim-Avionics 737ng
By ncleme in forum OpenCockpits General DiscussionReplies: 3Last Post: 11-09-2008, 07:25 AM -
Avionics Master Switch vs. Avionics Switch???
By Tomlin in forum I/O Interfacing Hardware and SoftwareReplies: 4Last Post: 08-08-2008, 09:28 AM
Search Prettys Womans from your city for night
5.Sharing an Essay about PIC16F877