Page 1 of 1

Direct driver load

Posted: Thu May 09, 2019 1:38 pm
by Alpin-Flier
Hi Roar

I am on the final for my B737 homecockpit. Since I have several programs to load after P3D to connect hardware and software, I am looking for an automised start sequence. I use the very versatile AHK program for that. I am quite successful with it, but now I have a problem, when I try to load the NGX driver. I cannot use the standard OC4BAv4, because I cannot operate the B737NGX window/button from the AHK. So I tried to load sioc.exe, then with or without a short delay the OCP4NGX.exe. I tried it also the other way, but I get always the following error:

Error # 2: Connect to SIOC failure, might be a fire wall....

I declared all involved programs for free in the firewall, but this does not help. By the way, this is my AHK script, that allows start and stop interconnection by control-n and control-m:

DetectHiddenWindows, On
^n::
run C:\SIOC\sioc.exe
sleep 1000 ;delay of 1 sec
run C:\SIOC\OCP4NGX.exe
run C:\SIMIO\SC-PASCAL7\Projects\B737NGX.exe
run .... ;other programs, e.g. motion control
return

^m::
winclose SIOC ; closes also OCP4NGX
winclose SC-PASCAL
run C:\SIMIO\SC-PASCAL7\Projects\AnzeigenAus.exe
sleep 1000
winclose SC-PASCAL
....
return

Any idea, what goes wrong? Or is there another (better) way to make the driver work? Any help is most appreciated.
Best regards
Urs

Re: Direct driver load

Posted: Thu May 09, 2019 2:36 pm
by Alpin-Flier
Hi Roar and all

In the meantime I had a closer look to the run command in AHK:
Run, Target [, WorkingDir, Max|Min|Hide|UseErrorLevel, OutputVarPID]

And now it is clear. I have to specify the WorkingDir, separated by a comma, then everything works fine. See the working code snippet:

run C:\SIOC\sioc.exe, C:\SIOC
run C:\SIOC\OCP4NGX.exe, C:\SIOC

Sorry for disturbing...
Best regards
Urs