Slashdot Mirror


Software Patch Fixes Mars Curiosity Rover's Auto-focus Glitch

An anonymous reader writes: Scientists from Los Alamos National Laboratory have successfully uploaded and applied a software patch to NASA's Curiosity Rover on Mars. The patch fixes a focusing problem that cropped up in November when the laser that helps to focus one of its cameras failed. "Without this laser rangefinder, the ChemCam instrument was somewhat blind," said Roger Wiens, ChemCam principal investigator at Los Alamos. "The main laser that creates flashes of plasma when it analyzes rocks and soils up to 25 feet [7.6 meters] from the rover was not affected, but the laser analyses only work when the telescope projecting the laser light to the target is in focus." Before the fix, scientists had to shoot images at nine different focus settings to distill a decent set of data. Now, they say the new software results in better images in a single shot than even before the laser broke down. The program that runs the instrument is only 40 kilobytes in size.

15 of 53 comments (clear)

  1. Source code? by Anonymous Coward · · Score: 5, Interesting

    Apollo space program is documented in great detail. Even the software running in the flight computers is nowdays available and you can run the whole thing in a virtualized guidance computer. http://www.ibiblio.org/apollo/

    Does anyone have any idea what's the case with probes and landers? I know they are mostly running VxWorks, but I'd love to take a peek on how some of the routines are actually implemented.

    1. Re:Source code? by jonwil · · Score: 3, Insightful

      Me, I wish the code for the Space Shuttle was available. The shuttles are now decommissioned and sitting in museums and no country wanting to build any kind of shuttle or space plane is going to be replicating a 40 year old American design when there are far better ways to do it nowadays so there shouldn't be any risk to national security in releasing the code (not to mention that the code alone isn't enough to rebuild the computer system, let alone the whole shuttle).

  2. Still a hack, but way better than nothing. by Mal-2 · · Score: 4, Interesting

    This fix still requires much of the resources of the previous method, essentially bracketing the shot and picking the best one. This means it will still take just as long to obtain each image, but apparently that wasn't a huge problem. What this saves is something precious though: bandwidth. Now the rover is picking the best shot, instead of sending a bunch of blind guesses and making us sort it out. I suspect that if the bandwidth wasn't precious, they wouldn't have bothered improving on the existing workaround, so it must have been worth all the trouble.

    --
    How is the Riemann zeta function like Trump rallies? Both have an endless number of trivial zeros.
    1. Re:Still a hack, but way better than nothing. by Anonymous Coward · · Score: 2, Interesting

      Technically you don't even need a range finder.

      It's possible to do autofocus through-the-lens with phase detection or contrast detection:

      Contrast detection places different constraints on lens design when compared with phase detection. While phase detection requires the lens to move its focus point quickly and directly to a new position, contrast detection autofocus instead employs lenses which can quickly sweep through the focal range, stopping precisely at the point where maximum contrast is detected. This means that lenses designed for phase detection often perform poorly on camera bodies which use contrast detection.

      From a link in TFA:

      They figured out that if they discarded a lot of the old code on board their distant subject, they could make room for software that could command the instrument to take the nine images on its own and analyze them on-board to find the best focus.

      I guess they didn't have room on the device to code up a binary search of the contrast method before acquiring a single image?

    2. Re:Still a hack, but way better than nothing. by citizenr · · Score: 3, Informative

      so it sounds like a simple FFT to pick one with biggest high frequency coefficients. You can do it yourself smapping pictures at different focus and simply comparing file sizes: better focus = finer detail = more high frequency content = more information to store. Think JPG Quantization table and quality setting.

      --
      Who logs in to gdm? Not I, said the duck.
    3. Re:Still a hack, but way better than nothing. by Anonymous Coward · · Score: 2, Informative

      And more importantly, it saves a lot of power. The MMRTG power supply is supposed to last 14 years. However, that's at very low consumption levels

      RTGs do not work that way; they're decaying whether you use the energy or not.

  3. "Only" 40 Kilobytes ?! by NotInHere · · Score: 3, Funny

    thats four times LiteOS! Get some Huawei developers work on this, and they'll reduce this patch to 64 bytes.

    1. Re:"Only" 40 Kilobytes ?! by Tablizer · · Score: 4, Funny

      thats four times LiteOS! Get some Huawei developers work on this, and they'll reduce this patch to 64 bytes.

      "64 bytes oughtta be enough for any Martian."
          - Marvin Gates

    2. Re:"Only" 40 Kilobytes ?! by Applehu+Akbar · · Score: 4, Funny

      "Get some Huawei developers work on this, and they'll reduce this patch to 64 bytes."
      And the hardened, high-capacity espionage backdoor channel to the PLA will serve mankind well should a solar flare takes out our primary communications channel with Curiosity.

  4. The program that runs the instrument is only 40 ki by Runaway1956 · · Score: 2

    We need these guys to work on Firefox. Chromium too! Hell, just turn them loose on Windows!

    --
    "Windows is like the faint smell of piss in a subway: it's there, and there's nothing you can do about it." - Charlie Br
  5. Not a fix... by Alwin+Henseler · · Score: 5, Informative

    ..but an improved workaround.

    If I read the article(s) correctly, problem was caused by failure of a small 2nd laser used for range finding. It seems that failure wasn't solved. Permanently out of action? Who knows.

    Workaround was to take several shots at different focus settings, and have home base sort out the data. Improved workaround is to take several shots at different focus settings, have software on-site figure out which are the best, and only send that data back home.

  6. To the editors by Crashmarik · · Score: 4, Interesting

    If you are going to have a story like this it would be good form to remember the H, aka HOW from who,what,when,where, why and HOW of a journalism article. At some point in the past this was a site oriented to the technical community, most of whom are very interested in the how. You might even think that for the most part the when, why, where and who are all at the who cares level. (Mars being an exception)

    1. Re:To the editors by umghhh · · Score: 2

      I do not know this so I am guessing but it may be that the number of people that are so limited (deep Asperger and any such)) as to not care about anything other than 'how' is limited which means that as the /. crowd grew, they became increasingly outnumbered. You may be displeased by this of course but if you are old enough you will understand that this is unavoidable. I dislike all the information foam around subjects too. I still learned how to cope. Filter the necessary stuff yourself it is not that difficult. BTW: In some cases the infofoam carries some vital clues needed to communicate with the rest of humanity. I did not believe that either but painful lessons of the past taught me to change my perspective.

  7. Re:The program that runs the instrument is only 40 by itzly · · Score: 2

    Nobody in their right mind is going to write rover code in assembly. Too much work, and too much chance of a silly mistakes fucking things up, while the actual code saving is not much. It's much easier and cheaper to add some extra memory instead.

  8. and pay some technical debt by Ducho_CWB · · Score: 2

    "Now, they say the new software results in better images in a single shot than even before the laser broke down."

    So it was a good Oportunity to pay some technical debt.