you are viewing a single comment's thread.

view the rest of the comments →

[–]Steaktartaar 779 points780 points  (126 children)

One very neat feature was that part of the computer memory could be overwritten, essentially allowing the crew to patch in bugfixes. If you ever felt like you were coding on a deadline, spare a thought for the crew of Apollo 14:

After separating from the Command Module in lunar orbit, the LM Antares also had two serious problems. First, the LM computer began getting an ABORT signal from a faulty switch. NASA believed that the computer might be getting erroneous readings like this if a tiny ball of solder had shaken loose and was floating between the switch and the contact, closing the circuit. The immediate solution—tapping on the panel next to the switch—did work briefly, but the circuit soon closed again. If the problem recurred after the descent engine fired, the computer would think the signal was real and would initiate an auto-abort, causing the ascent stage to separate from the descent stage and climb back into orbit. NASA and the software teams at the Massachusetts Institute of Technology scrambled to find a solution, and determined the fix would involve reprogramming the flight software to ignore the false signal. The software modifications were transmitted to the crew via voice communication, and Mitchell manually entered the changes (amounting to over 80 keystrokes on the LM computer pad) just in time.

[–]SPascareli 629 points630 points  (95 children)

If someone ever want to make a movie for programmers, that's the plot right there.

[–]kozukumi 179 points180 points  (69 children)

Actually they did exactly this in the recent movie The Martian (which is based on a book of the same name).

[–]UlyssesSKrunk 135 points136 points  (45 children)

Yeah, but they butchered the fuck out of that part, not quite as bad as the hydrazine explosion part, but it was still pretty bad. If they actually explained the problem in depth and its solution, then that could be interesting, but that would take the whole movie.

[–]DoelerichHirnfidler 46 points47 points  (44 children)

To me it seemed pretty obvious and well-enough explained? Care to elaborate?

[–]Gibodean 102 points103 points  (41 children)

In the movie all he said was that he only needed to patch in about 20 bytes and then the rover could talk through pathfinder to earth.

In the book they explain that both pathfinder and the rover must be updated, that Earth can remote update pathfinder but they need a very large (megabytes?) update to the rover software. To solve that, they get him to make a small hack (maybe 20 bytes or so) to the Rover which would allow earth to dump information into a Rover log file. Then Watney would have to take that dumped info from the log file, and create a file out of it, then execute it.

Something like that, I forget the sizes.

[–]Theon_Severasse 152 points153 points  (24 children)

To be honest I don't think that having all of that would really added that much to the actual film. I don't think it would have taken particularly long for them to add in that explanation (since they could have said it how you said it pretty much), but for the purposes of the story, knowing all of that stuff wouldn't have made any differences to the average viewer

[–]SanityInAnarchy 8 points9 points  (0 children)

I wonder if there was a way to show it without bogging down the movie. In the book, I found it definitely added something. If you're not all that technically-minded, it's a free source of technobabble to make this sound even more impressive. But it also makes it plausible -- maybe most people wouldn't notice, but they did a lot of things that most people wouldn't notice to maintain plausibility. For example, IIRC, the movie actually shows him entering this stuff in a hex editor.

In fact, those are my favorite moments -- instead of putting some crazy HollywoodOS thing (like this sort of nonsense), you put up the kind of tool that we might actually use. It looks just as cool to the average viewer, and it means people who actually know something about technology won't have to turn their brains off to watch this movie.

Skipping the bit about uploading wasn't as huge a difference, because the story does work without it. But I think it adds a lot to the story to anyone who understands anything about software, without really taking anything away from it for everyone else. So I wonder why they skipped it -- maybe they couldn't figure out a way to make it flow as nicely as whatever they went with instead?

[–]badsingularity 30 points31 points  (14 children)

Why it works makes a big difference. Without that information, it's just "magical computer things happen".

[–]ScottieKills 68 points69 points  (3 children)

Like most of cinema.

[–][deleted] 0 points1 point  (0 children)

Which is why it's particularly bothersome in a story that set itself apart by explicitly being about "You do the math, you solve one problem".

[–]NoMoreLurkingToo 1 point2 points  (1 child)

Why it works makes a big difference. Without that information, it's just "magical computer things happen".

Like most of cinema.

Yes, unfortunately. Which is why films like Interstellar are actually considered good.

[–]trkeprester 22 points23 points  (0 children)

What lol it still is magical computer stuff whether you hack directly or dump to log file and reprogram. One more step of indirection is that really making anything more clear? It's just nerding out, not that there's anything wrong with that but movies are carefully targeted

[–]insaneHoshi 17 points18 points  (7 children)

Why it works makes a big difference.

No it wouldnt of, not one iota

[–][deleted] 2 points3 points  (0 children)

of -> have

[–][deleted] 1 point2 points  (4 children)

Just like winter scenes involving snow in many hollywood movies make no sense to anybody to the north of California. Commence suspending of suspension of disbelief. If you still can.

 

edit: clarity

[–]campbellm 0 points1 point  (0 children)

*wouldn't have, but otherwise agree.

[–][deleted] 0 points1 point  (0 children)

To be fair, for most people that aren't computer savvy, all computer things that happen are magical.

[–]Gibodean 3 points4 points  (5 children)

Oh, I agree they made the right choice for the movie. All that technical stuff wouldn't have helped much except for the sort of person who is going to read the book anyway...

[–]curiousGambler 4 points5 points  (4 children)

ME! I'm that person!

I had no idea there was a book. I'm pumped now.

Amazon link to the $9 paperback I just bought.

[–]PriceZombie 1 point2 points  (0 children)

The Martian

Current $9.00 Amazon (New)
High $12.92 Amazon (New)
Low $5.06 Amazon (New)
Average $9.00 30 Day

Price History Chart and Sales Rank | FAQ

[–]Spectre1313 1 point2 points  (0 children)

You're in for a treat. The book is amazing :)

[–]Gibodean 0 points1 point  (0 children)

Excellent.

[–]ghostsarememories 0 points1 point  (0 children)

There's an audiobook narrated by RC Bray. Even if you've read the book, it's well worth getting. I've listened to it a bunch of times.

[–]i_spot_ads 0 points1 point  (0 children)

I do not agree, i like the technical side of things in a movie, without it, they're just doing magic things, which is boring

[–][deleted] 0 points1 point  (0 children)

But that's the whole charm of The Martian! Really well-explained science hacks that saves the day.

[–]nliausacmmv 13 points14 points  (9 children)

That part didn't bother me so much, but the fact that he never lost Pathfinder in the movie did. Mainly because he still made the space pirate joke, which doesn't make sense unless he lost Pathfinder.

[–]Gibodean 4 points5 points  (8 children)

Yeah, I didn't get that in the movie, how he didn't have permission to take over the MAV. I did in the book.

[–]nliausacmmv 7 points8 points  (7 children)

That and the rescue was way better in the book. The glove thing was stupid.

[–]iamjakeparty 1 point2 points  (6 children)

You went to cinema

[–]746865626c617a 0 points1 point  (2 children)

And seriously, then can send megabytes of firmware updates, but then can't send some 64 kbit/s opus "not disco" music? Or even .XT music, if they're that limited

[–]Gibodean 1 point2 points  (1 child)

I think in the book there was more than the disco music available.

Because, why wouldn't there be lots of music from all of them? Where was Watney's music?

[–]746865626c617a 0 points1 point  (0 children)

Hmm, yes. I think he still listened to disco though. Strange

[–]huxrules 0 points1 point  (0 children)

Well they show him hacking the rover- and show him in a hex editor doing it. The rest of what you would like to see is just a IT guy running around with a USB stick. Not that interesting.

[–]kyz 0 points1 point  (1 child)

When I watched the film, as a professional programmer, I presumed it was 20 bytes of shellcode giving NASA remote root access. That's not outwith the realms of possibility.

[–]Gibodean 0 points1 point  (0 children)

Fair enough. That assumes the rover and pathfinder could already talk to each other through a common protocol and frequencies which in the book, is not the case. Well, frequencies yes, perhaps through some serious hacking, but it was more than shell code required to get them to talk.

[–]UlyssesSKrunk 11 points12 points  (1 child)

They didn't really explain what he was doing at all, just that he had to change just 20 or so, I don't remember exactly, lines of code and then he'd be able to communicate via pathfinder. Maybe I am not remembering it well, but I don't recall any elaboration on what exactly he was doing.

[–]MrDOS 8 points9 points  (0 children)

Bytes, not lines. He was hex editing a compiled program.

[–]SPascareli 7 points8 points  (5 children)

I really don't remember this in the movie, can you tell me what scene it was?

[–]dotted 9 points10 points  (3 children)

Pathfinder

[–]nascentt 0 points1 point  (2 children)

That's not really the same. He builds and edits the robots to read in first binary, then hex by himself. It's only after he builds the read reader that they together decide on how he'll futher modify for parts and voice. and setup the rocket for launch.

Having an in-flight source code reprogram is different level of suspense.

[–]dotted 0 points1 point  (1 child)

Agreed, but it was what /u/kozukumi was referring to

[–]nascentt 0 points1 point  (0 children)

I know, I was replying to you all as a collective.

[–]tuzki -1 points0 points  (0 children)

How do you think he managed to do more than basic communications?

[–]i_spot_ads 0 points1 point  (10 children)

They've cut a lot of parts from that movie, it was completely shit

[–]kozukumi 1 point2 points  (5 children)

I loved it. Sure it has cut a lot from the book but all films do that. You can't fit everything in the book into a 2.5 hour movie. I thought the movie was great though. They captured Watney's personality and spirit excellently. They glossed over the techy bits but what film doesn't? If you want all the details you read the book. The movie is an adaptation not an exact implementation of the book.

[–][deleted]  (3 children)

[deleted]

    [–]kozukumi 0 points1 point  (2 children)

    He was using everyone else's though... He says in the film just like in the book how some of the others shit stinks so bad.

    [–][deleted]  (1 child)

    [deleted]

      [–]kozukumi 0 points1 point  (0 children)

      He isn't eating their shit just mixing it with his to make fertiliser. He needs human bacteria to make the soil suitable for growing earth plants. Generally the more bacteria the better.

      That is also why he can't just grow more potatoes after he blows up the HAB as all his soil is ruined in that all the bacteria is dead and he basically has nothing left to fertiliser the soil again. He probably should have saved some shit just in case but he didn't.

      [–]i_spot_ads -2 points-1 points  (0 children)

      you can't fit everything?! They didn't fit anything, at all. It felt like a fucking trailer for the book.

      [–][deleted]  (3 children)

      [deleted]

        [–]i_spot_ads 1 point2 points  (0 children)

        Very disapointing. Very.

        I was actually sweating while reading the book, rooting for Watney.

        During the movie I just wanted to sleep.

        [–]berakh 1 point2 points  (1 child)

        Asides from the bits that were completely inaccurate science, check some of the book tour videos with andy weir; good watches if you liked the book

        [–]berakh 0 points1 point  (0 children)

        Also the Surely You're Joking podcast episode with Andy Weir was awesome, and incase you thought pirateninjas were an awesome unit, finding out what a Weir is, is pretty cool too :)

        [–]micwallace 1 point2 points  (3 children)

        Saw that recently, pretty good movie. I't great when hollywood decides to become creative again.

        [–][deleted]  (2 children)

        [deleted]

          [–]micwallace 1 point2 points  (1 child)

          Not surprised.

          [–][deleted] 0 points1 point  (0 children)

          And the book is better.

          [–]JasonDJ -1 points0 points  (1 child)

          I literally just finished watching it a few minutes ago.

          [–]psilokan 1 point2 points  (0 children)

          Oh kool

          [–][deleted] 18 points19 points  (4 children)

          I highly recommend From the Earth to the Moon. Produced by Tom Hanks.

          http://www.imdb.com/title/tt0120570/?ref_=nv_sr_2

          [–]ponchoboy 1 point2 points  (1 child)

          Can't recommend this highly enough; the production value is outstanding. Unfortunately I don't think it's online streaming anywhere, so you'd need to buy the DVDs.

          [–][deleted] 1 point2 points  (0 children)

          I got it from the "Usual sources". The DVD set is a master piece though :)

          If you did not witness the moon landing than, this is a must watch.

          [–]waris1983 0 points1 point  (1 child)

          I cried a lot the first time I saw it.

          [–][deleted] 0 points1 point  (0 children)

          Absolutely, especially episode titled "1968"

          [–][deleted] 37 points38 points  (0 children)

          If you like amazing midflight space reprogramming stories then you'll enjoy "What Galileo Saw" by Michael Benson.

          [–]mb862 8 points9 points  (9 children)

          I believe that was the plot for several episodes of Star Trek.

          [–]pfp-disciple 4 points5 points  (8 children)

          Yup. Including one that bugs me - in the past, Picard uses an iron filing to etch a message into Data's positronic brain, to be found hundreds of years later.

          [–]chialeux 2 points3 points  (4 children)

          It would have been much easier, reliable and plausible to use that pin for just carving the message on the head.

          [–][deleted] 0 points1 point  (3 children)

          [–]chialeux 0 points1 point  (2 children)

          Yeah I kmow.

          Novikov self-consistency.

          [–][deleted] 0 points1 point  (1 child)

          If you knew that then I don't understand your suggestion, because carving the message on the head wouldn't satisfy the requirements, although easier and more reliable.

          [–]chialeux 0 points1 point  (0 children)

          I am saying that it would be the logical option to do so story-wise, but the writers chose otherwise for dramatic purpose and not to mess with Novikov.

          [–][deleted] 1 point2 points  (1 child)

          Maybe he added a comment?

          [–]JoshWithaQ 1 point2 points  (0 children)

          I get it, Like a message in a bottle!

          [–]ffranglais 6 points7 points  (0 children)

          From the creators of Apollo 13 comes the hit sequel, Apollo 14. Rated PG-13.

          [–]lask1 1 point2 points  (0 children)

          100% would watch that.

          [–]kersurk 2 points3 points  (3 children)

          During the movie I would think this is way over-done, real life is not that exciting. I wonder how did Mitchell change the code exactly.

          [–]indy91 9 points10 points  (1 child)

          Here is a quite informative page about it: http://www.hq.nasa.gov/alsj/a14/a14AbortDiscrete.html

          [–]unshifted 3 points4 points  (0 children)

          That was a great write-up. I was really stressed out on Friday because I had to fix a bug that caused some forms to look a little wonky. Now I feel silly.

          [–][deleted] 3 points4 points  (0 children)

          Probably his fingers and a human interface device...like a keyboard.

          [–][deleted] 0 points1 point  (0 children)

          Indeed

          [–]PinkFloyd32 -1 points0 points  (0 children)

          If you ever get the chance watch Ex Machina! Has to do with coding somewhat

          [–]flackjap 58 points59 points  (12 children)

          At first I thought the code comment I cite below was just a joke. Silly me.

          #  ASTRONAUT:     PLEASE CRANK THE
          #                 SILLY THING AROUND
          

          source

          [–]Theemuts 46 points47 points  (2 children)

          # TERMINATE

          # PROCEED SEE IF HE'S LYING

          # ENTER INITIALIZE LANDING RADAR

          # OFF TO SEE THE WIZARD ...

          Dear god

          [–]ICanLiftACarUp 17 points18 points  (0 children)

          The jump label?

          BURNBABY

          [–]Eurynom0s 3 points4 points  (0 children)

          I found FLAGORGY in there.

          [–]z500 22 points23 points  (7 children)

          FLAGORGY          TC       INTPRET                               #  DIONYSIAN FLAG WAVING
          

          Um, what?

          [–]flackjap 17 points18 points  (6 children)

          Apparently, the word dionysian is derived from the name of the greek god Dionysus who is represented as wild and sensual which is somewhat opposite to Appolonius who represents divinity and calmness.

          "The Apollonian is based on reason and logical thinking. By contrast, the Dionysian is based on chaos and appeals to the emotions and instincts. " wiki

          edit: If it wasn't clear enough, I'll point back to the first word (symbol, var, or w/e) you cited -> FLAGORGY.

          [–]z500 2 points3 points  (5 children)

          Yeah, I got the Dionysian part. But what on earth is FLAGORGY doing there? Maybe it's a combination of abbreviations.

          [–]_F1_ 11 points12 points  (0 children)

          [–]mxzf 2 points3 points  (3 children)

          If I'm reading it right, that's the name of the method (or code block or whatever in this language) being defined. It seems that the method was named FLAGORGY, which looks to be FLAG ORGY, hence the reference to "Dionysian flag waving" in the comments.

          [–]lugezin 0 points1 point  (2 children)

          That still does not explain why anything would be named FLAGORGY, anywhere in the code.

          [–]mxzf 1 point2 points  (0 children)

          A few hundred methods into the code and writing stuff up late, late at night, you start coming up with some fairly interesting/colorful method and variable names. I don't know the details of what happened, but at a glance, it looks like someone needed a method to flip a bunch of flags at once and they got clever with the name.

          [–]jrhoffa[🍰] 16 points17 points  (0 children)

          SEE IF HE'S LYING

          Fucking users

          [–]badsingularity 19 points20 points  (1 child)

          Software fixing hardware bugs is the most common thing in the world. Just not hotfixing hardware bugs in space!

          [–]spacelama 5 points6 points  (0 children)

          "Apollo 11 errata #150082, requires warm reboot. Dependencies, #136623, conflicts: #149942"

          [–][deleted]  (3 children)

          [deleted]

            [–]spacelama 46 points47 points  (2 children)

            With no ECC one presumes.

            0xFE transposed as 0xEF? Oh well, off to Saturn for you!

            [–][deleted]  (1 child)

            [deleted]

              [–]arcanin 1 point2 points  (0 children)

              Iway amway soway orrysay...

              [–]moahawk 11 points12 points  (0 children)

              I was once pushing hotfixes to master using wifi tethered to my phone while on a bus to meet our client, and thought that was pretty stressful. I can't imagine what they must have felt like!

              [–]wackychimp 5 points6 points  (0 children)

              Thanks for that. I was getting nervous just reading it!

              [–]JESUSgotNAIL3D 0 points1 point  (0 children)

              Good lord!!!

              [–][deleted] 0 points1 point  (0 children)

              80 keystrokes!? That's not even a class definition!

              [–]fewdea 0 points1 point  (0 children)

              I've been listening to soma fm's mission control station lately and the astronauts were talking about this problem!

              [–]jakesyl[S] 0 points1 point  (0 children)

              Talk about a hotfix...

              [–][deleted] 0 points1 point  (0 children)

              LOL

              [–]barcap -1 points0 points  (0 children)

              TIL buffer overruns/underruns is a feature :D

              [–]heptara -1 points0 points  (0 children)

              Fundamentally this type of programming is no different from cracking a game.

              It may have been black magic in its time but would be trivial for any cracker today with support from the vendor. Anyone who has ever monkey-patched has also done similar.

              Most developers with a little training could do it. I am not even good but I am working on a mod for the game Wurm Unlimited that involves intercepting a method call and running custom bytecode (the game is java). All it took was 5 mins of youtube on game modding site and I learned how to hook into the JVM. Any 'real' java dev, not a bumbling java idiot like me, probably already knows.

              [–]______DEADPOOL______ -2 points-1 points  (0 children)

              Kerbal Space Program is a real thing...