Jump to content
The simFlight Network Forums

FSUIPC offset 5428 througth Sioc


Recommended Posts

Hello!!

 

i have a problem im not able to solve!

 

i have built my own cdu and as hardware im using open cockpits usb_keys!  the software is through iokeys and Sioc wich talk to

fsuipc! In FSUIPC im running the buttons through offset 5428 (im using project magenta boeing cdu)

in SIOC i wrote a script so FSUIPC will recognize it like a virtual joystick. 

Everything works perfectly until some minutes or if i have pressed the buttons to many times.. (i dont know wich of it)

but then the buttons just stop working.. not everyone but it seems the more buttons i press more of them stops to work!

FSUIPC just dont respond on buttons anymore...

but in SIOC and IOkeys everything seems to work so its not hardware problem..

the strange thing is when i restart SIOC fsuipc responding again.. but same thing will happen again!

So i dont know if it is a SIOC problem or FSUIPC issue! or just a bad script? but it works perfectly a while!!

in the script i have made 3 different joysticks because i have more than 64 buttons..

i dont know how familiar you are with SIOC but i post  a part of the script here so you have a hint (maybye)

im a beginner to use SIOC!

 

var 1 name KEY Link USB_KEYS device 0
{
  L0 = &KEY
  IF L0 = 61
  {
    &FO_JoyStick64 = TOGGLE 0   //  A
  }
  IF L0 = 62
  {
    &FO_JoyStick64 = TOGGLE 1   //  B
  }
  IF L0 = 59
  {
    &FO_JoyStick64 = TOGGLE 2   //  C
  }
 }

 

Var 2 name FO_JoyStick64 Link FSUIPC_OUT Offset $3340 Length 4

 

 

just a part of script but it looks the same later just i create more joysticks.

i posted this thread on mycockpit to, to see if someone can help me but i havent found anything by myself

on internet about this..

 

maybye you have an idea!

 

Regards Tommy

Link to comment
Share on other sites

Everything works perfectly until some minutes or if i have pressed the buttons to many times.. (i dont know wich of it)

but then the buttons just stop working.. not everyone but it seems the more buttons i press more of them stops to work!

FSUIPC just dont respond on buttons anymore...

but in SIOC and IOkeys everything seems to work so its not hardware problem..

 

 

There's not enough information here for me to help I'm afraid. I don't know SIOC and can't help that end, but I would need to see some logging to help with the FSUIPC end.

 

Add 5428 (as type U16) and the three virtual button joystick offsets (as type U32 with hex option checked) to the Monitor on the right hand side of the FSUIPC logging tab and check "normal Log" below. Also enable Button Logging. Then when this happens check the log. For FSX you could also see what is happening in real time by putting FSX into windowed mode and displaying the FSUIPC console log next to it.

 

You need to check if the offsets are changing and if so that the offset 5428 is reflecting your programming. If so, then you are going to need PM support because it will be at the CDU end of things.

 

Regards

Pete

Link to comment
Share on other sites

  Hello!!

 

i maybye some more info!!

 

i logged in fsx what u told me.. the files are getting pretty long

 

what i see on screen for example

 

i press button 75

 

ipc:5428 (S16) 75

ipc:3340 (U32)0x400

ipc:3344 (u32)0x00

ipc:3348 (U32)0x00

 

and then in the normal case everything go back to zero

 

BUT!

 

when it starts to get stucked it can look like this

 

ipc:5428 (S16) 75

ipc:3340 (U32)0xC8E

ipc:3344 (u32)0x00

ipc:3348 (U32)0x00

 

and i can never press this button again unless i restart SIOC..

 

and i noticed when this start to happen i can only press every button one more time!

i dont know if you want a entire log file to see  until it starts to happen?

 

i dont know if this help you at all? or me...

 

another question..

 

is it possible to start and stop a program on another computer on network via FSUIPC? with a keypress from server not "Run option" i havent seen any option about that..

because if its possible i can just stop and start sioc until i solve this..

 

Regards

 

Tommy

Link to comment
Share on other sites

i logged in fsx what u told me.. the files are getting pretty long

 

 

Of course. it's logging all you do. but only the parts leading to the problem are relevant.

 

 

what i see on screen for example

 

i press button 75

 

ipc:5428 (S16) 75

ipc:3340 (U32)0x400

ipc:3344 (u32)0x00

ipc:3348 (U32)0x00

 

 

 

 

Er. I don't understand: Button 75 looks to be joystick 64, Button 18? Why do you call it 75? And offset 5428 is logged as being set to 75, how? What is doing that, and why BEFORE button 18 is shown pressed?

 

and then in the normal case everything go back to zero

 

 

 

Everything? 5428 goes to zero, and all the virtual buttons?

 

when it starts to get stucked it can look like this

 

ipc:5428 (S16) 75

ipc:3340 (U32)0xC8E

ipc:3344 (u32)0x00

ipc:3348 (U32)0x00

 

 

5428 became 75 again? How?

 

You aren't showing me the logging of the button actions, so it is simply confusing showing things out of context.

 

The 3340 offset now shows 6 buttons still pressed, including the one mentioned earlier! Are you really holding them pressed or doesn't your SIOC programmer clear the bits when you release the button?

 

Still I have insugfficient information I'm afraid.

 

and i can never press this button again unless i restart SIOC..

 

 

 

Because it seems the bit showing it pressed remains set and your SIOC never clears it!

 

 

and i noticed when this start to happen i can only press every button one more time!

i dont know if you want a entire log file to see  until it starts to happen?

 

 

 

You should be able to see if SIOC is clearing the bits correctly in 3340 etc when you release the button.  Maybe it cannot do this, in which case you would probably need to try to set it to toggle the bit (ie invert it), and program both the "press" and "release" to do the same thing.

 

is it possible to start and stop a program on another computer on network via FSUIPC? with a keypress from server not "Run option" i havent seen any option about that.

.

 

 

If you haven't "seen any option about that" you presumably are not using WideFS or have not looked at its documentation? Any program can be started from a KeySend assignment and similarly closed. Check "RunKey" and "CloseKey" parameters.

 

Regards

Pete

Link to comment
Share on other sites

Maybe it cannot do this, in which case you would probably need to try to set it to toggle the bit (ie invert it), and program both the "press" and "release" to do the same thing.

 

 

If this is what you have to do, it would make sense to program the Release part to have one of the spare upper bits set in the Key encoding so you can type successive identical letters, as in EGLL. If yyou don't change 5428 PM will not pick up identical successive letters, so with a normal "press/release" button action you'd need to program each button in the FSUIPC INI file to use a flag to toggle one of the top bits on and off on alternate entries.

If SIOC can manage it, wouldn't all this be better with SIOC writing the values directly to 5428 rather than indirectly through virtual buttons and fSUIPC assignment, or are you needing to program it differently for different aircraft via Profiles?

 

Regards

Pete

Link to comment
Share on other sites

Hello pete!!

 

I think you helped me to solve it last night!!

 

you wrote "Because it seems the bit showing it pressed remains set and your SIOC never clears it!"

 

and that started me to think about that again.. i had that in my sioc script before to "0" after every keypress, but it didnt work..

but i found out if i put "delay" command to it, it seems to work!!

 

So the script look like this now! can be good for others with usb_keys

 

var 1 name KEY Link USB_KEYS device 0
{
  L0 = &KEY
  IF L0 = 61
  {
    &FO_JoyStick64 = TOGGLE 0   // toggle bit 0 of joystick 64
    &FO_JoyStick64 = Delay 0 20
  }

 

 

Before i had just &FO_JoyStick64 = 0 and then it zeroed all the time and nothing happend when i pressed the button!!

So it seems it was a sioc problem or more human factor problem, but i havent really got time to test it fully but it never froze in 30 min last night!!

 

thank u for taking time anyway!

 

 

"If you haven't "seen any option about that" you presumably are not using WideFS or have not looked at its documentation? Any program can be started from a KeySend assignment and similarly closed. Check "RunKey" and "CloseKey" parameters."

 

Sorry about that, havent worket with flightsim and fsuipc almost nothing last year.. i will read documentation about that! it can be a really nice function for me!!

 

 

Thank you!

 

Regards

 

Tommy

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

.

 

 

 

 

 

 

 

Link to comment
Share on other sites

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.