If you are an aircraft/plugin developer we should team up as parts of the sim are being used/controlled by both parties.



External power provided by jetways

From SAM 2.0.6 on SAM jetways support external power, if the scenery author activates it. All WorldJetways objects are enabled for external power by default.


Default logic: When the jetways gets connected to an aircraft, we set sim/cockpit/electrical/gpu_on to 1, on disconnect we switch it back to 0. We only do that once when the jetways connection gets triggered, not permanently.


Custom logic: If you're using a custom external power code you can synch that with the dataref sam/jetway/externalpower/on. The logic is the same like above mentioned. Additionally you should override sim/cockpit/electrical/gpu_on manipulation by setting sam/jetway/externalpower/override to 1.




Controlling jetway connections via API

SAM 2.0.8 introduces an API to connect and disconnect jetways to a specific door location. You can use it to connect jetways to static/AI aircrafts for example.


Connect jetway to door location: http://localhost:20205/jetway/connect?

Disconnect jetway from door location: http://localhost:20205/jetway/disconnect?


Add the following mandatory attributes after "?" in the URL, each seperated by "&"


door world coordinate
y=door world coordinate
z=door world coordinate
psi=aircraft heading
door_psi=door rotation relative to the aircraft heading
door_location=LF1 | LF2 | LU1 
animate=true | false -> if you need instant connections i.e. for initial startup sequence use false

IMPORTANT ADVICE: If you connected a jetway to a specific location please use exactly the same string with all values for disconnecting it again. Because the local coordinates can change when the user moves around the jetway won't disconnect if you if you determine the coordinates for the disconnect again manually. Just put a "dis" before connect into the string and you are good.

Our test scenery is VABB (get it here) and the following coordinates would be appropriate for the SAM_TEST_RAMP startup location:

http://localhost:20205/jetway/connect?x=-13527.526367&y=-165.964020&z=45411.640625&psi=359.834717&door_psi=0.0&door_location=LF1&animate=true


http://localhost:20205/jetway/disconnect?x=-13527.526367&y=-165.964020&z=45411.640625&psi=359.834717&door_psi=0.0&door_location=LF1&animate=true

Please note that a disconnect only works, if you used the API to connect it. You can't control the jetway connected to the user aircraft.




If you have any questions feel free to get in touch.