Cockpitbuilders.com

Main => Builders Discussions => Topic started by: vuelosat on March 25, 2012, 11:22:11 AM

Title: Help with sioc programig ADF module - boeing 737 NG
Post by: vuelosat on March 25, 2012, 11:22:11 AM
Hi all,
Does anyone know how to encode the SIOC for the ADF pannel, for the boeing 737 please ? The code you'll find below works, but I can't find the offset of the ADF standby when using Peter Dowson's list and the FS Interrogate program.
The only offsets I can find are the ADF frequency and the ADF extended one. The pannel I am currently using has two slots that show the digits of the Active ADF and the Standby ADF.
I really hope one of you can help me in modifying the code so I can display the Standby ADF (now that I can't display the Standby ADF, the encoder directly modifies the Active ADF).
I don't know if it helps, but for additionnal information, I am using Prosim 737.


//*********************************************
//*****                ADF                  ***
//*********************************************




Var 0500, Value 34 // ENTEROS 1 ADF1 VALOR INICIAL 3
{
CALL V0507
}

Var 0501, Value 30 // DECIMAL ADF1 VALOR INICIAL 0
{
CALL V0507
}

Var 0502, Link IOCARD_ENCODER, device 1,  Input 209, Aceleration 2, Type 2 // ENTEROS 1 ADF1
{
V0500 = ROTATE 10 ,179 ,V0502
}

Var 0503, Link IOCARD_ENCODER, device 1, Input 207, Aceleration 2, Type 2 // DECIMALES ADF1
{
L0 = V0503 * 1
V0501 = V0501 - L0
IF V0501 > 95
{
V0501 = 0
}
IF V0501 < 0
{
V0501 = 95
}
}

Var 0504, Link IOCARD_DISPLAY, device 1, Digit 181, Numbers 5 // SALIDA A LOS DISPLAYS ADF1

Var 0505, Link FSUIPC_OUT, Offset $034C, Length 2

Var 0506, Link FSUIPC_OUT, Offset $0356, Length 2

Var 0507, Link SUBRUTINE // MONTA EL NUMERO ADF1
{
L0 = V0500 * 100
L0 = L0 + V0501
V0504 = L0 // NUMERO MANTADO PARA DISPLAY
L0 = V0504 / 10
L0 = TRUNC L0
V0505 = TOBCD L0 // DEC A BIN ADF1 FREC
L0 = V0500 / 100
L0 = TRUNC L0
L0 = L0 * 100
L0 = L0 + V0501
V0506 = TOBCD L0 // DEC TO BIN ADF1 FREC EXT
}


(https://www.cockpitbuilders.com/proxy.php?request=http%3A%2F%2F2.bp.blogspot.com%2F-zhA3zuy4YwY%2FT29ulSWEeUI%2FAAAAAAAAAdM%2F--3woADNkDE%2Fs1600%2Fla%2Bfoto.JPG&hash=f0ea6c2b26c4da1ee9a83da8386b53248e848ea5)
Title: Re: Help with sioc programig ADF module - boeing 737 NG
Post by: Kennair on April 02, 2012, 04:17:34 AM
Hi Vuelosat,  there is no offset for the ADF Standby hence the reason why you can't find it  :).  Try my attached code kindly written by Nico Kaan (http://www.lekseecon.nl/) who is the pre-eminent SIOC wizard in my book (I would highly recommend reading his SIOC tutorials if you want to learn more).  This will give you control over the frequency by two encoders, one operating the 2 higher digits and one operating the 2 lower digits and it also gives you a standby frequency via the code itself and will pass it to FS once you press the Transfer button.

Ken.
Title: Re: Help with sioc programig ADF module - boeing 737 NG
Post by: vuelosat on April 06, 2012, 12:34:51 AM
thank you.
Now is working.