Mischung
02-23-2015, 03:41 PM
Hi,
I'm just coding for my home-built OVH and came across some problems regarding the switch position after starting SIOC.
What I'm using:
- P3D 2.4
- iFly 737 CBE
- iFlyToFSUIPC
- SIOC (of course) + 3 Mastercards, etc...
After starting everything the switches are not in sync with the simulation (the LEDs are). I hoped that SIOC would read the switch-positions and then send it to the sim, but it does not :cry: Or it does it for some switches (read somewhere that this is a known problem).
I then tried to use "Var 0" and call some init subroutines in my different sections:
Var 0 Value 0
{
v1 = DELAY 1 100 //call init routines after 1s
}
Var 1
{
CALL &InitBleed
...
}
Then I created subroutines (in my bleed section) for every switch and tried to call them within one function:
Var 1 name InitBleed Link SUBRUTINE
{
CALL &TRIM_SWITCH
CALL &L_REC_SW
CALL &R_REC_SW
...
}
:( Not working -> only the last switch will go to the correct position :(
Then I put some delay in between (which looks terrible in SIOC ;)):
Var 1 name InitBleed Link SUBRUTINE
{
CALL &TRIM_SWITCH
&InitBleed1 = DELAY 1 10
}
Var 2 name InitBleed1
{
CALL &L_REC_SW
&InitBleed2 = DELAY 1 10
}
Var 3 name InitBleed2
{
CALL &R_REC_SW
&InitBleed3 = DELAY 1 10
}
...
Now it's working and after ~1 s all the coded switches are in sync :D
BUT: Is this really the way to do it?
It's not good looking code in my opinion.
Maybe anyone has a good idea how to do it?
Thanks for any hints...
Marc
I'm just coding for my home-built OVH and came across some problems regarding the switch position after starting SIOC.
What I'm using:
- P3D 2.4
- iFly 737 CBE
- iFlyToFSUIPC
- SIOC (of course) + 3 Mastercards, etc...
After starting everything the switches are not in sync with the simulation (the LEDs are). I hoped that SIOC would read the switch-positions and then send it to the sim, but it does not :cry: Or it does it for some switches (read somewhere that this is a known problem).
I then tried to use "Var 0" and call some init subroutines in my different sections:
Var 0 Value 0
{
v1 = DELAY 1 100 //call init routines after 1s
}
Var 1
{
CALL &InitBleed
...
}
Then I created subroutines (in my bleed section) for every switch and tried to call them within one function:
Var 1 name InitBleed Link SUBRUTINE
{
CALL &TRIM_SWITCH
CALL &L_REC_SW
CALL &R_REC_SW
...
}
:( Not working -> only the last switch will go to the correct position :(
Then I put some delay in between (which looks terrible in SIOC ;)):
Var 1 name InitBleed Link SUBRUTINE
{
CALL &TRIM_SWITCH
&InitBleed1 = DELAY 1 10
}
Var 2 name InitBleed1
{
CALL &L_REC_SW
&InitBleed2 = DELAY 1 10
}
Var 3 name InitBleed2
{
CALL &R_REC_SW
&InitBleed3 = DELAY 1 10
}
...
Now it's working and after ~1 s all the coded switches are in sync :D
BUT: Is this really the way to do it?
It's not good looking code in my opinion.
Maybe anyone has a good idea how to do it?
Thanks for any hints...
Marc