News:

Precision Simulator update 10.184 (15 September 2025) is now available.
Navburo update 13 (23 November 2022) is now available.
NG FMC and More is released.

Main Menu

Worldflight 2024

Started by macroflight, Sat, 5 Oct 2024 09:41

macroflight

#60
I decided to try writing a PSX router/broker/multiplexer in Python, and to not cheat and ask Hoppie how its done. :)

So far I have something (190 lines of Python using asyncio) that accepts connections on port 10748 from one or more clients and makes a single connection to a the PSX main server on port 10747.

After some tinkering I got it to work for at least a normal PSX client and some addons written using Hoppie's psx.py library.

Since the code has no useful features that socat does not already provide, I will not ask for any testers right now.

But this opens up the possibility to do lots of things, e.g
- Logging traffic for addon debugging
- Internet-facing router with built-in access control for shared cockpit (e.g based on IP address, but possibly using an authentication token sent via the addon= message)
- Connecting to a remote shared cockpit PSX server instead of a local PSX server. Apart from making it easier to switch between shared cockpit and normal sim, the router could also filter out unwanted control input (e.g if your controls are noisy and you don't want to send updates to the master sim unless you are pilot flying)
- Read-only connections (e.g based on client IP)

(code: https://github.com/macroflight/psxhacks/blob/devel/frankenrouter.py)

voipmeister

Looking forward to test it with you  :)
Seb

macroflight

Quote from: Jeroen Hoppenbrouwers on Thu,  5 Jun 2025 05:37So I need to get back to work on my PSX-native ACARS (CPDLC) client, which should be perfectly fine on a shared cockpit as it shares the displays but not the ACARS link. Run the client on one cockpit, and the displays of the other cockpit should pick it up.

Somebody could try that today ...
https://www.hoppie.nl/psx/python/psx-acars.html
I tried psx-acars-beta-00 and it works fine for me. Not in shared cockpit mode, but I can't imagine why that would break anything. It's still just one PSX sim.

I don't suppose there's a psx-acars-beta-01 hidden anywhere? :)

Jeroen Hoppenbrouwers

... sticks reminder on screen ...