MobiFlight Community Support

Welcome to the forum for MobiFlight! Feel free to reach out to the community in case you have questions, issues or just want to share great ideas or details about your latest home cockpit project.

You like MobiFlight? Donate via PayPal and support the MobiFlight development. Thanks! 

icon
Avatar
jpcdias
Posts: 6
Hello my friends,
i have been working on my transponder and everything was great until i started to change the frequency. Well, i can show in the 7 segment display the frequency but when i turn my encoders to change the value it doesn't work. I am using eventID which should increment the 1000, the 100, 10 and 1 positions. Well it doesn't work at all and i can't find any Offset for it.

I have tried in FSX and it works perfectly, but my friends .... i am using X-plane 11.

Anyone can help me with this ?

Thanks in advance.

JonnyTech
2018-06-04 11:38
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 2732
Supporter
Nope...

Xplane using XPUIPC.... ( Instead of FSUIPC in FSX)

In Xplane ( As i know) you can NOT use EventID ! Thats only for FSX/P3D and not included in XPUIPC.

If you like to change a value in Xplane via XPUIPC you need to directly write the Offset !

Check " Offset: 0354 Size 2 Byte Transponder setting : 4 digits in BCD format: 0x1200 means 1200 on the dials.

Note: I Not try out if XPUIPC is working simmular to FSUIPC here. Maby this is finaly not possible at all.
You must do lots of testing.... Or you find a guy here that have done it before.

I Recommend to test this maby in FSX first ( Without Event and by writing this offset) .... If it work then test same config in XPlane ...
Just to prevent a problem in XPUIPC.
So first find out how the logic should look like.... Then test it in both systems !

EDIT:
In case this is verry problematic and a high workflow..... Think about to set this 4 Encoders Via Joystick Input.
Pretty shure much more comfortable !!
Good Luck !
2018-06-04 12:48
Avatar
jpcdias
Posts: 6
Thanks pizman82. I will give a try. If i get to a success point i will let you know.

Best

Jonny
2018-06-04 12:52
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 2732
Supporter
Just a additional Note....

I remember to a other guy that reqested this in a personal Email contact maby 1-2 Years ago. ( Not find the mail again after a reinstall of my PC :cry: )

The problem was ( if i remember right) that Mobiflight can READ a "part" of a byte ( With Bitmasking) BUT Mobiflight can NOT WRITE a "part" of a Byte via Bitmask.

So you have a Problem here i think.

Offset is BCD coded.... Means... Its a 2 Byte Offset including 4 Numbers . So its split in 4 Nibbles (Halfbytes) ....
Bit 0-3 of Byte 1 (Offset 0354) is ONE Number .... Bit 4-7 of Byte 1 ( already Offset 0354) is another Number .
Same on next Byte ( Offset 0355 ) Bit 0-3 is a Number and bit 4-7 is the last Number.

To SET a Number you need to Read it first.... Thats Possible. You will mark for example the Bits 0-3 in BCD Mode and output should be the correct Number of your XPDR Frequency.

Now the logical next step would be a formula (Example increase rightturn of encoder) is $+1 !
Or to protect a Overflow behind 7 ( XPDR goes form 0-7) you need : if($=7,0,$+1)

but NOW the PROBLEM:
If i remember right it is NOT Possible to Write a bitmask Input to a decimal value only 1/0 is possible.... AND it is not possible to write multiple bits individual....
So 4 Bits marked and a write of "1" will write all bits same time " 1 1 1 1 " .... A Write with "0" is do the same "0 0 0 0 "
(Check this for more information : https://www.mobiflight.com/forum/message/4824.html German topic.... Use Translator if needed)


Summary....
I Think for THIS You need a difficult technic.... Maby with a "verry" detailed IF condition ( Lots of ELSE IF) it is possible.... Maby Modulo%% is needed too.
A bit easyer should be to set 2 Numbers together.... So your encoder turn for example the Left two diggits ....
For Example XPDR 12xx ... A Rightturn of encoder will set 13xx ..... On 17xx the next turn will set 20xx and so on.
This should be possible.... Whatever its not comfortable and also verry difficult to do

*****
A already would recommend to think about joystick system !
Good Luck !
2018-06-04 16:14
Avatar
StephanHo
From: EDDG, Germany
Posts: 1315
Supporter
Annotation:

The transponder does not transmit on any frequency. In air traffic, the transponder code is a pilot-set four-digit octal number (numbers 0-7) which the aircraft transponder transmits when polled by the ground station's secondary radar. The transponder code (also called squawk) is displayed together with the radar echo on the radar screens of the air traffic control and serves in a flight information area for the unique identification of an aircraft. In aircraft, therefore, the assigned squawk is always set, no frequency (exception: standard VFR flights should set code 7000 - earlier 0021 and 0022).

To summarize of pizman: The "upshifting" of a transponder code beyond one digit (for example, from 1700 to 2000 on the 3rd digit) is not common to my knowledge and in practice also cumbersome. How long should a controller wait for the Squawk to be set or if a wrong number has been set?
Grüße,
Stephan
2018-06-04 19:48
Avatar
pizman82
Moderator
From: ETSI, Germany
Posts: 2732
Supporter
I know Stephan....
thats why im said
iconQuote:

" Whatever its not comfortable and also verry difficult to do"



But in that special situation that mobiflight not can write a 4 bit block single i thought about a write of a 8 bit block ( so 2 numbers together) is maby more possible.

But finaly this must be tested.... In the past i not try it with BCD Mode.
I can confirm that it is not possible to write 2 bits individual (like i explane in the linked BUG Report. ) With e.g. Bit 0 and 1 marked it is not possible to write 1-0 or 0-1 You can only write 1 or 0 and that result in 11 or 00.

BUT "Maby" it´s possible to write a 4 bit marked block with the BCD System !!! Thats what i don´t know and never try out.

Let´s wait for a reply of "jpcdias". Then we all know more about !
Good Luck !
2018-06-04 22:59
Avatar
StephanHo
From: EDDG, Germany
Posts: 1315
Supporter
Is it possible to write decimal numbers?

$ and 2dez - set bit 1, $ and 3dez sets the bits 0&1 and so on. I mean to write the decimal equivalent to manipulate the bits.
255dez set all bits 0...7, 128dez only bit 7 and so on.
[Last edited by StephanHo, 2018-06-05 18:27]
Grüße,
Stephan
2018-06-05 15:48
Avatar
jpcdias
Posts: 6
Thanks a lot for the explanation. I will give a try and then i give you feedback.

Best
Jonny
2018-06-05 17:20
Avatar
StephanHo
From: EDDG, Germany
Posts: 1315
Supporter
@Jonny: please pay attention! That was a question of mine :confused:
Grüße,
Stephan
2018-06-05 18:28
Avatar
azminear@gmail.com
Posts: 13
read this but I am confused, I just set up my transponder squawk freq by using 4 separate encoders, then using the fsuipc offset increment the value by $-1000 for down or $+1000 for up on the left most encoder, then by 100, 10 and 1 for the other encoders. It seems to work just fine on my xplane.
2019-01-19 00:52
icon