16 comments

[ 4.3 ms ] story [ 41.4 ms ] thread
Well, if we're posting out autopilots, here is my solution:

Code: https://gist.github.com/inariakagane/58a65db8c9d629b00d55621...

Video in action: https://www.youtube.com/watch?v=e-QTZWGFVc8

I find your use of the Chrome driver as an execution medium pretty neat! Mine works... usually. An occasional failure just to let people put their training to the test.

I’m imagining an astronaut floating off into the void saying, “The docking algorithm doesn’t always work, but we knew the risks. Thanks for trying! Please tell my spouse that I’m sorry that I forgot to take out the trash.”
If you would like to try writing an Autopilot bot yourself, I've made a script that adds a text editor to the page and hooks it into the simulation. You can then implement a control function that on each frame receives the current position and velocity, and returns movement commands that the spacecraft will execute:

https://github.com/andrey-leshenko/ISSDockingBotGame

My strategy is to line all the axis up at the beginning and then I don't touch anything but forward, and back. This works 100% of the time.

Am I playing it wrong?

Given that the docking simulator is blissfully oblivious about real-life orbital dynamics and attitude control problems, you are playing the simulator right.

For more verisimilitude, use Orbiter.

Could it simulate these dynamics better by just adding a little noise?
Is this affiliated to SpaceX?
The simulator was released by them ahead of the first crewed SpaceX flight. The UI is based on the real UI of the spacecraft.
Interesting project! A while back I made something similar in Clojure: https://news.ycombinator.com/item?id=23257195

One tip - I noticed that you use XPath selector and send click events, however you can simply send keyboard events to the browser. But overall I like that the solution is quite similar! One thing is - might be worth merging the Axis modules into one and make it parametrised.

The competition shouldn't be if you can do it, but how fast you can do it.
There is usually a tradeoff between fast and fuel-conserving (also between fast and safe), and the real life maneuvers are extremely slow.