STS-125

STS-125, or HST-SM4 (Hubble Space Telescope Servicing Mission 4), was the fifth and final space shuttle mission to the Hubble Space Telescope (HST). Launch occurred on 11 May 2009 at 2:01 pm EDT. Landing occurred on 24 May at 11:39 am EDT, with the mission lasting a total of just under 13 days.

carried two new instruments to the Hubble Space Telescope, the Cosmic Origins Spectrograph and the Wide Field Camera 3. The mission also replaced a Fine Guidance Sensor, six gyroscopes, and two battery unit modules to allow the telescope to continue to function at least through 2014. The crew also installed new thermal blanket insulating panels to provide improved thermal protection, and a soft-capture mechanism that would aid in the safe de-orbiting of the telescope by an unmanned spacecraft at the end of its operational lifespan. The mission also carried an IMAX camera with which the crew documented the progress of the mission for the Hubble IMAX movie.

The crew of STS-125 included three astronauts who had previous experience servicing Hubble. Scott Altman visited Hubble in 2002 as commander of STS-109, the fourth Hubble servicing mission. John Grunsfeld, an astronomer, has serviced Hubble twice, performing a total of five spacewalks on STS-103 in 1999 and STS-109. Michael Massimino served with both Altman and Grunsfeld on STS-109, and performed two spacewalks to service the telescope.

NASA managers and engineers declared the mission a complete success. The completion of all the major objectives, as well as some that were not considered vital, upgraded the Hubble telescope to its most technologically advanced state since its launch nineteen years before and made it more powerful than ever. The upgrades will help Hubble to see deeper into the universe and farther into the past, closer to the time of the Big Bang.

STS-125 was the only visit to the Hubble Space Telescope for Atlantis; the telescope had been previously serviced twice by Discovery and once each by Columbia and Endeavour. The mission was the 30th flight of Space Shuttle Atlantis and also the first by Atlantis in over 14 years not to visit a space station, the last one being STS-66.

Mission history
The fifth servicing mission to Hubble, HST-SM4, was originally scheduled to launch in late 2005 or early 2006. On 16 January 2004, then-NASA Administrator Sean O'Keefe canceled the mission, as well as any future missions to Hubble, citing safety constraints imposed by the Columbia Accident Investigation Board. During the announcement, O'Keefe stated that it was his decision alone, and not a recommendation from any other departments. The decision was widely criticized by the media, the science community, and those in NASA. Maryland Senator Barbara Mikulski, a member of the Senate subcommitte that oversees NASA's budget, publicly accused O'Keefe of making a decision outside the transparency process against the wishes of the science community, and stated she would work to reverse the decision. In March 2004, Representative Mark Udall introduced a bill to the House of Representatives that requested an independent panel of experts review O'Keefe's decision to cancel the servicing mission. Also in March 2004, Space Telescope Science Institute (STScI) Director Stephen Beckwith released the results of the Hubble Ultra-Deep Field survey to the entire science community, which helped show the public how important Hubble was to science. The data showed the deepest images ever taken by a telescope and revealed approximately 10,000 galaxies, some of which most likely dated back to when the universe was just five hundred million years old. With Beckwith when he released the data to the scientific community was Mikulski, who said of the results, "I think it's just amazing... this is why I will continue to stand up for Hubble."

Joining Mikulski as an advocate for servicing Hubble was NASA's Chief Scientist, physicist John Grunsfeld, who was present at the meeting when O'Keefe announced the cancellation of the mission. A veteran astronaut of four shuttle missions, including two Hubble servicing missions, Grunsfeld had devoted years to Hubble, and was very disappointed when O'Keefe canceled the mission. He briefly considered retiring from NASA, but realized if he stayed, he could continue to advance physics in other ways. Instead, Grunsfeld dedicated himself to finding alternate ways to service the telescope, possibly by sending a robot into orbit to do the job. When O'Keefe announced his resignation as Administrator in December 2004, five days after a National Academy of Sciences committee opposed O'Keefe's position regarding servicing Hubble, the media and science community saw hope for the telescope's servicing mission to be reinstated.

O'Keefe's replacement, Michael D. Griffin, took just two months after his appointment to announce that he disagreed with O'Keefe's decision, and would consider sending a shuttle to repair Hubble. As an engineer, Griffin had previously worked on Hubble's construction, and respected the discoveries the telescope brought to the science community. He agreed with the National Academy of Sciences that a robotic mission was not feasible, and said that in light of the "Return to Flight" changes made following the Columbia accident, a shuttle mission to repair Hubble should be reassessed. After the successes of the Return to Flight STS-114 and STS-121 missions, and the lessons learned and improvements made following those missions, managers and engineers worked to formulate a plan that would allow the shuttle to service Hubble, while still adhering to the post-Columbia safety requirements.

On 31 October 2006, Griffin announced that the Hubble servicing mission was reinstated, scheduled for 2008, and announced the crew that would fly the mission, which included Grunsfeld. Senator Mikulski expressed her delight at the news, stating "The Hubble telescope has been the greatest telescope since Galileo invented the first one. It has gone to look at places in the universe that we didn't know existed before."

New Yorker and dedicated New York Mets fan, Mike Massimino, brought the home plate from Shea Stadium along on the mission. He was forced to slightly alter the plate to allow it to fit into the locker designated for memorabilia. Massimino presented the plate back to the Mets management upon return and threw out the first pitch there. The plate is now on display at Citi Field.

Mission payload
The mission added two new instruments to Hubble. The first instrument, the Cosmic Origins Spectrograph, is now the most sensitive ultraviolet spectrograph installed on the telescope. Its far-UV channel is 30 times more sensitive than previous instruments and the near-UV is twice as sensitive. The second instrument, the Wide Field Camera 3, is a panchromatic wide-field camera that can record a wide range of wavelengths, including infrared, visible, and ultraviolet light. Atlantis also carried the Soft-Capture Mechanism, which was installed onto the telescope. This will enable a spacecraft to be sent to the telescope to assist in its safe de-orbit at the end of its life. It is a circular mechanism containing structures and targets to aid docking.

The infrastructure of the telescope was upgraded by replacing a "Fine Guidance Sensor" that controls the telescope's directional system, installing a set of six new gyroscopes, replacing batteries, and installing a new outer blanket layer to provide improved insulation.

The payload bay elements were the Super Lightweight Interchangeable Carrier (SLIC) which held the Wide Field Camera 3, new batteries, and a radiator; the ORU Carrier which stored the Cosmic Origins Spectrograph and FGS-3R instruments; the Flight Support Structure (FSS) which held onto the Hubble during repairs;, the Multi-Use Lightweight Equipment Carrier (MULE) which held support equipment and the Relative Navigation Sensor (RNS) Experiment.

Along with the collectible items that are flown on shuttle missions, such as mission patches, flags, and other personal items for the crew, were an official Harlem Globetrotters basketball and a basketball that Edwin Hubble used in 1909 when he played for the University of Chicago. After being returned to Earth, the Harlem Globetrotters basketball would be placed in the Naismith Memorial Basketball Hall of Fame, and Hubble's ball would be returned to the University of Chicago. Michael Massimino flew a 1964 reprint of Galileo's Sidereus Nuncius from the library of his alma mater, MIT.

IMAX movie
At the end of September 2007, Warner Bros. Pictures and IMAX Corporation announced that in cooperation with NASA, an IMAX 3D camera would travel to the Hubble telescope in the payload bay of Atlantis for production of a new film that will chronicle the story of the Hubble telescope. An IMAX camera was also stationed at the LC-39 Press Site for the launch. IMAX has made a number of movies centered around space, including Destiny in Space, The Dream Is Alive, Mission to Mir, Blue Planet, Magnificent Desolation: Walking on the Moon 3D, and Space Station 3D, made in 2001 on the first trip of IMAX to the ISS. The movie was released in March 2010, with the name IMAX: Hubble 3D.

Media
Astronaut Michael J. Massimino used Twitter to document the training and preparations for the mission. He mentioned that he would like to try sending Twitter updates from space during his off-duty time. Massimino's first update read, "From orbit: Launch was awesome!! I am feeling great, working hard, & enjoying the magnificent views, the adventure of a lifetime has begun!" Massimino was the first person to use Twitter in space.

Mission background
The mission marked:


 * 157th NASA manned space flight
 * 126th shuttle mission since STS-1
 * 30th flight of Atlantis
 * 53rd shuttle landing at Edwards Air Force Base
 * 101st post-Challenger mission
 * 13th post-Columbia mission

Shuttle processing
STS-125 was first assigned to Discovery with a launch date no earlier than May 2008. This originally moved the mission ahead of STS-119, ISS Assembly flight 15. Delays to several shuttle missions resulted in a change in mission ordering, and the orbiter was changed to Atlantis on 8 January 2007. The crew of Atlantis went to the Kennedy Space Center for the Crew Equipment Interface Test in early July 2008. This allowed the STS-125 crew to get familiar with the orbiter and the hardware they would be using during the flight.

Launch delays
On 22 August 2008, after a delay following Tropical Storm Fay, Atlantis was rolled from the Orbiter Processing Facility to the Vehicle Assembly Building, where it was mated to the external fuel tank and solid rocket booster stack. Problems were encountered during the mating process, and poor weather due to Hurricane Hanna caused a delay in the rollout of Atlantis to the launch pad, which is normally done seven days after rollover.

STS-125 was further pushed back to October 2008 due to manufacturing delays on external tanks for future space shuttle missions. Lockheed Martin experienced delays during the production changes to make new external tanks with all the enhancements recommended by the Columbia Accident Investigation Board, making it impossible for them to produce two tanks for the STS-125 mission–one for Atlantis, and one for Endeavour for an emergency rescue mission, if necessary–in time for the original August launch date.

The first rollout to Launch Pad 39A occurred on 4 September 2008. On 27 September, the Science Instrument Command and Data Handling (SIC&DH) Unit on the Hubble Space Telescope failed. Because of its importance to the telescope, NASA postponed the launch of STS-125 on 29 September until 2009 so the failed unit could be replaced as well. Atlantis was rolled back to the Vehicle Assembly Building on 20 October.

On 30 October 2008, NASA announced that Atlantis would be removed from its solid rocket boosters and external tank stack and sent back to the Orbiter Processing Facility to await a targeted launch time at 1:11 pm EDT on 12 May 2009. The stack was turned over to be used on the STS-119 mission instead. On 23 March, Atlantis was mated to its new stack in the Vehicle Assembly Building, and rolled out to Launch Pad 39A on 31 March. On 24 April 2009, NASA managers issued a request to move the STS-125 launch up one day to 11 May at 2:01 pm EDT. The change was made official at the flight readiness review on 30 April. The reason cited for the change was to add one more day to the launch window, from two to three days.

11 May (Flight day 1, launch)
Following a smooth countdown, Atlantis launched on time at 2:01 pm EDT. Almost immediately after launch and during the ascent, flight systems reported problems with a hydrogen tank transducer and a circuit breaker; the crew was immediately advised to disregard the resultant alarms and continue to orbit. During the post-launch news conference, NASA managers said the initial early review of the launch video showed no obvious debris events, but a thorough analysis would be performed to ensure the orbiter sustained no significant damage during ascent. After working through their post launch checklists, the crew opened the payload bay doors, deployed the Ku band antenna, and moved into the robotic activities portion of the day, which included a survey of the payload bay and crew cabin survey with the orbiter's robotic arm.

During the post-launch inspection of Launch Pad 39A, a twenty-five foot area on the north side of the flame deflector was found to have damage where some of the heat resistant coating came off. Following the launch of STS-124, severe damage was seen at the pad where bricks were blasted from the walls, but NASA officials stated the damage from the STS-125 launch was not nearly as severe and should not impact the launch of STS-127 in June.

12 May (Flight day 2)
Following the morning wake up call, the crew set right to work on the day's tasks, which were centered on inspection of the orbiter's heat shield. Using the shuttle robotic arm and the Orbiter Boom Sensor System (OBSS), the crew went through a detailed inspection of the orbiter's thermal protection system (TPS) tile and Reinforced carbon-carbon (RCC) surfaces. During the inspection, engineers on the ground noticed a small area of tile on the forward area of the shuttle's right wing that appeared to have suffered some damage during ascent. Mission managers called up to the crew to alert them of the find, advising Altman ("Scooter") that one of the orbiter's wing leading edge sensors recorded a debris event during ascent, around 104 – 106 seconds following liftoff, which may have been the cause of the damage seen in that area. CAPCOM Dan Burbank advised the crew that the damage did not initially appear to be serious, but assured the crew that the image analysis team would be reviewing the imagery further, and engineers on the ground would be analyzing it to determine if a focused inspection would be required.

As part of the Flight Day 2 Execute Package, ground engineers also provided further information on the circuit breaker failure seen at launch. The breaker (Channel 1 Aerosurfaces, ASA 1) is part of the shuttle's Flight Control Systems (FCS), a subsystem of the Guidance, Navigation and Control (GNC) systems. The failure would have no impact to the mission, due to redundant systems.

In addition to the survey of the orbiter's heat shield, the crew gathered and inspected the EVA tools and spacesuits that would be used for the mission's spacewalks and prepared the Flight Support System (FSS) for berthing with Hubble on flight day three.

13 May (Flight day 3)
Following the crew's post-sleep activities, they went to work performing the rendezvous operations that included burning the orbiter's engines to refine the approach to the Hubble telescope. Following some delays due to communications issues, Altman and Johnson ("Ray-J") guided the orbiter within fifty feet of the telescope. McArthur successfully grappled Hubble at 17:14 UTC, and at 18:12 the telescope was safely berthed in the payload bay of Atlantis. Later in the day, Grunsfeld and Feustel (Drew), along with Good ("Bueno") and Massimino ("Mass") worked on preparing for the next day's spacewalk, gathering tools and checking out the suits and equipment that would be used during the EVA.

At the Mission Management Team (MMT) briefing, MMT Chairman LeRoy Cain reported that the damage assessment team had cleared all of the orbiter's TPS tiles and blankets, and were expected to clear the RCC portion of the orbiter by flight day four. He stated that no focused inspection would be required. Cain also noted that a debris event was recorded on the orbiter's wing leading edge sensors, but it was far below the force that would indicate a problem, and would not impact the mission. The late inspection that is routinely performed prior to re-entry would give any additional information, but Cain stated "We're not concerned that it's done any kind of damage that would be any concern to us, certainly not critical damage."

During the Mission Status briefing, Lead Flight Director Tony Ceccacci noted that during the camera survey of the equipment in the payload bay, the team noticed some fine particulate matter around the box containing the Wide Field Camera 3 and asked the crew to take additional images using a higher resolution camera for the ground teams to assess. Cain later confirmed that the dust was not present prior to launch, and was most likely particulate shaken loose from the thick insulation blankets inside the payload bay during launch. The team advised the crew to avoid the particulate as much as possible during the spacewalks, and use caution when working around the container to avoid the debris, but it was not a significant concern.

14 May (Flight day 4)
Following the crew's wake up, they set to work preparing for the mission's first spacewalk. Grunsfeld and Feustel suited up with the assistance of their EVA counterparts, Massimino and Good, and the spacewalk officially began when the two switched their suits to battery power at 12:52 UTC. At the start of the spacewalk, Feustel provided managers on the ground with a visual inspection report on the particulate matter seen earlier around the WFC3 box, reporting to the ground team that "I don't really see any of those particles...It's almost imperceivable. I can see some few particles on the front of the W-SIPE, little, whitish, grey looking, real small. It's low density, too." After getting their tools and equipment for the EVA set up, Grunsfeld and Feustel removed the old Wide Field and Planetary Camera 2, which was installed in 1993 during the telescope's first servicing mission, and replaced it with the new Wide Field Camera 3 (WFC3). Feustel initially had trouble removing the bolts from the old camera, which after over fifteen years in space required more torque to remove than expected. After multiple attempts, managers on the ground decided to have Grunsfeld get a contingency torque limiter from the airlock, which would allow Feustel to apply more force without exceeding a specific point, but the bolt would still not release. The concern was that the bolt would shear, and the camera would be unable to be removed should that happened. Finally, managers approved Feustel to remove the limiter, and apply as much force as he safely thought it would take to release the bolt, which was successful.

The new camera will allow Hubble to take large-scale, extremely clear and detailed photos over a wider range of colors than the old camera did. After the installation, controllers at the Space Telescope Operations Control Center at Goddard Space Flight Center sent commands to the camera to perform an aliveness test, which passed, indicating the camera was installed correctly.

The next task was to remove and replace the telescope's Science Instrument Command and Data Handling Unit, or SIC&DH, a computer that sends commands to Hubble's science instruments, and formats science data for transmission to the ground. This was the item that failed in September 2008, delaying STS-125 while engineers prepared a replacement part for the mission, and the crew trained for the new task. While the failure of the SIC&DH did not disable the telescope, replacing the unit restores the redundancies. The final major task was to install the Soft-Capture Mechanism (SCM), which includes the 72 in Low Impact Docking System (LIDS) that will allow spacecraft in the future to dock with the telescope, and to safely de-orbit the telescope at the end of its life. Feustel also installed two of four Latch Over Center Kits, or LOCKs, that make opening and closing Hubble's large access doors easier for the remaining spacewalks. The spacewalk officially ended at 20:12 UTC, for a time of seven hours and twenty minutes. It was the nineteenth spacewalk devoted to servicing the telescope, and brought the total time in servicing Hubble to one hundred thirty-six hours, thirty minutes. Due to the length of the spacewalk, and the delay in beginning, the crew was over an hour behind their scheduled timeline for the day, but worked through the post-EVA activities and evening activities without problems, and got to sleep only slightly behind their scheduled time. During the mission status briefing, David Leckrone, Hubble Project Senior Scientist, noted he was very relieved that the camera was replaced successfully, and noted that the problems with the bolt caused some concern, "I don't normally reveal my age and I'm not going to here, but I can tell you I'm five years older now than I was when I came to work this morning, we can sleep pretty well tonight, knowing that's been accomplished."

15 May (Flight day 5)
Following their wake up, the Atlantis crew set right to work preparing for the second spacewalk of the mission, with Massimino and Good suiting up with assistance from Grunsfeld and Feustel. As they were preparing for the EVA, the team on the ground informed the crew that the WFC3 had passed all the overnight functional tests, indicating it was in good working order.

While the spacewalk preparations were underway, Altman and McArthur completed a robotic survey of a small row of heat shield tiles that had not been sufficiently imaged during the day two inspection. Following the analysis of the survey, the managers cleared all of the TPS systems until the pre-landing inspection.

The mission's second spacewalk officially began at 12:49 UTC, and the pair set to work removing and replacing the telescope's three gyroscope rate sensing units (RSUs). Each unit contains two gyroscopes that allow the telescope to point itself. The first unit, RSU 2, was replaced without problems, but when they attempted to replace the second unit, RSU 3, the unit would not align onto the guide pins, and they could not seat it into the equipment bay. Managers decided to put the unit originally intended for the RSU 1 bay into the RSU 3 bay, and it was installed without problems. The pair then attempted to install the second unit into the third and final bay, but the unit again would not seat properly, and they were unable to install it. Instead, it was decided that an additional unit carried as a spare would be placed into the final bay. The spare unit was one that was removed during the STS-103 mission, and had been refurbished on the ground. The installation of all three gyro units was a critical objective of the servicing mission, as three had failed, one was offline due to electrical issues, and the other two had also been experiencing issues with performance. Ground controllers at Goddard Space Flight Center confirmed that all six gyroscopes and the new battery passed preliminary tests.

The problems with seating the second RSU set the spacewalkers back in the timeline by approximately two hours, but after Altman asked Massimino and Good how they felt, they replied they were doing well and felt fine to continue. Flight controllers on the ground evaluated the consumables for the two spacesuits, and decided that if Massimino recharged his suit's oxygen in the airlock, the pair could safely continue with the battery installation. After moving to the battery unit site, Good and Massimino removed one of the original battery modules from Bay 2 of the telescope, and replaced it with a new unit. The batteries provide power to the telescope when it passes into the Earth's shadow and its solar arrays are not exposed to the sun. The spacewalk officially ended at 20:45 UTC, for a time of seven hours, fifty-six minutes. It was the twentieth spacewalk to service Hubble, bringing the total time in EVA servicing the telescope to one hundred forty-four hours and twenty-six minutes.

During the mission status briefing, Tomas Gonzalez-Torres, the Lead EVA Officer, and Hubble Program Manager Preston Burch both explained that the spare RSU would not impact the life of the telescope, as it had been fully refurbished on the ground with two of the three improvements incorporated in newer models. "I would say the difference in the projected longevity of the observatory in the out years is very small. We don't see this is a significant detriment at all to the observatory. This was a tremendous accomplishment for us." Burch noted. Lead Flight Director Tony Ceccacci noted that due to the length of the spacewalk, and the resulting slip in the timeline, the crew's sleep shift would have to be moved an hour later, to allow them to get the proper amount of rest, and the rest of the docked timeline would also be shifted forward an hour.

16 May (Flight day 6)
After awakening, the crew set to work preparing for the mission's third spacewalk, one that was considered the most challenging and uncertain, yet had some of the highest priority items scheduled. The tasks were to remove the obsolete Corrective Optics Space Telescope Axial Replacement (COSTAR), originally installed during STS-61 to correct the spherical aberration of Hubble's mirror, and install the Cosmic Origins Spectrograph (COS), and to repair the Advanced Camera for Surveys (ACS). The ACS failed in June 2006 due to an electrical issue, and after being restored partially, failed again in 2007 due to an electrical short. The ACS was not designed to be serviced or repaired in space, so the task was considered one of the most challenging of the mission. After running into various snags in the first two spacewalks, managers on the ground were prepared to see unexpected issues arise during the complicated repair work. The spacewalk began at 13:35 UTC, and Grunsfeld and Feustel had no problems. The pair worked through their timeline so efficiently that they were over an hour ahead at one point. After removing COSTAR and stowing it in the orbiter's payload bay, they installed COS, and then moved on to the ACS repair. Using specially designed tools, they removed an access panel, replaced the camera's four circuit boards, and installed a new power supply.

The spacewalk was completed in six hours and thirty-six minutes, and the ACS passed the initial aliveness tests. It was the twenty-first Hubble servicing spacewalk, and Grunsfeld's seventh EVA, moving him up to fourth in the record book of spacewalking time. During the previous day's mission status briefing, Dave Leckrone, Hubble Space Telescope Senior Project Scientist, made a prediction, joking that since the first two spacewalks, which were considered to be straightforward, had run into issues, the most difficult EVA – to repair the ACS, would be the smoothest one of the mission. "I have a prediction, We've always said EVA 3 was going to be the most difficult and the most challenging, and I predict it's going to go more smoothly than any other EVA on this mission. I just think that's some version of Murphy's Law that's going to lead us in that direction."

After the initial aliveness testing, the ACS was put through its functional tests. Managers and engineers had noted that the repairs were designed for only one of the three photo channels, the wide-field channel, and that the issues with the high-resolution channel may not be resolved by the designed fix. During the functional testing, the wide-field channel passed, but issues were seen with the high-resolution channel, indicating that the power issue may be farther upstream in the electronic circuits than the spacewalk repair addressed. Additional testing would be performed, but Hubble Program Manager Preston Burch noted that the fix was designed to "back power" the high-resolution channel through the paths connected to the wide-field channel, and while feasible, it was a possibility that the short circuit damage was in an area not corrected with the planned repair. Even if the high-resolution channel is unable to be restored, it was considered to be less important, since the bulk of the ACS science output is undertaken by the wide-field channel. The third channel, the solar-blind channel, passed overnight functional testing without issues.

17 May (Flight day 7)
Beginning the mission's fourth spacewalk at 13:45 UTC, Massimino and Good went to work repairing the Space Telescope Imaging Spectrograph (STIS). The spectrograph failed in 2004 due to a blown power supply. As with the ACS, the STIS was not designed with the intention of servicing it while in space, and one of the major challenges was to remove a cover plate held tight with over 100 screws using a specially designed tool called a fastener-capture plate, designed to trap the screws and washers and prevent them from floating into space when removed. While preparing the fastener-capture plate, Massimino encountered issues with a handrail that had to be removed to accommodate the fastener-capture plate. The handrail had a stripped bolt on the bottom, preventing it from being released. After trying multiple options without success, managers on the ground advised Massimino to use brute force to remove the handrail, so he could proceed with the removal of the cover plate. The procedure was tested at Goddard Space Flight Center prior to approving it, showing that the stripped bolt could be broken off safely using force. Working inside the orbiter, Feustel walked Massimino through the procedure slowly, advising him to tape the handrail with Kapton tape to prevent any parts from breaking off or flying loose, to be aware of the reaction the force would have, as well as to watch for sharp edges on the handrail after removal.

Once the handrail was removed, Massimino went to work attaching the capture plate, but ran into additional problems when the battery in one of his power tools failed. Massimino was instructed to return to the orbiter's airlock to retrieve a spare tool and to recharge his suit's oxygen reserves, to allow for completion of the STIS repair. The rest of the STIS repair work was completed without any problems, but the spacewalkers were nearly two hours behind the scheduled timeline, so managers on the ground decided to postpone the task of installing a New Outer Blanket Layers (NOBLs) onto the telescope's outer shell. The spacewalk, originally scheduled to last six hours and thirty minutes, ended at 21:02 UTC, for a time of eight hours and two minutes. At the time, it became the sixth longest spacewalk in history. It was the twenty-second spacewalk devoted to servicing the Hubble telescope, and Massimino's fourth spacewalk, bringing his total EVA time to thirty hours, forty-four minutes.

During the mission status briefing, Jennifer Wiseman, Chief of Exoplanet and Stellar Astrophysics for Goddard Space Flight Center, noted that the repair of STIS was a major victory for both the mission and the science community, as that part of the telescope performed unique functions, helping scientists understand the materials planets are composed of, and looking at things like the motion of stars around black holes.

After initial aliveness testing that showed no issues, STIS was taken into functional testing, and issues were seen when the telescope put itself into safe mode due to a low thermal limit sensor. Ground controllers at Goddard would restart the testing once the thermal limit sensor was back in normal sensor range, but it is believed the component is in good shape.

18 May (Flight day 8)
Completing the fifth of the five planned spacewalks, Grunsfeld and Feustel successfully installed the second battery, removed and replaced the Fine Guidance Sensor number three, and worked so efficiently that they were over an hour ahead of the timeline, giving them time to remove degraded insulation panels from three bays of the telescope, and install three New Outer Blanket Layers (NOBLs). Beginning the spacewalk at 12:20 UTC, the pair first worked on removing an aging battery module, and replaced it with a new pack, which combined with the battery replacement performed during the second spacewalk, gave the telescope all new nickel-hydrogen batteries. They then moved on to the removal and replacement of the Fine Guidance Sensor unit number three, improving Hubble's focus and stability when imaging. NASA engineers liken the new FGS to being able to keep a laser beam focused on a U.S. dime coin that is 320 km away. Both the new batteries, and the FGS passed both aliveness and functional testing. The mission's final EVA concluded at 19:22 UTC, after seven hours and two minutes. The total time spent during the mission in extra-vehicular activity was thirty-six hours, fifty-six minutes. The twenty-third and final spacewalk to service Hubble brought the total time spent in EVA working on the telescope to one hundred and sixty-six hours, six minutes. Lead Flight Director Tony Ceccacci noted that the final EVA was also the last planned spacewalk from a shuttle airlock. In what was likely his last EVA, Grunsfeld's has accumulated fifty-eight hours and thirty minutes spacewalking, just two minutes less than Jerry L. Ross, who is third on the list of spacewalking time.

The completion of all the major objectives, as well as some that were not considered vital, upgraded the telescope to its most technologically advanced state since its launch nineteen years ago, and made it more powerful than ever. The upgrades will also help Hubble to see deeper into the universe, and farther into the past, closer to the time of the Big Bang. Hubble's importance to science is not just seen in the dramatic images it provides, but also in the volume of work it has generated – an average of fourteen scientific articles are published each week based on data gathered from the telescope. Officially, the upgrades should extend Hubble's life through 2014, but Hubble Space Telescope Senior Scientist David Leckrone noted prior to the mission that if all of the mission's objectives were successful, the telescope could easily last longer than that. The next large telescope scheduled to be launched is the James Webb Space Telescope in 2018, which is infrared-only, so to have Hubble, which has ultraviolet, visible, and near-infrared capabilities, still operational after 2018 would be of great benefit to the scientific community.

19 May (Flight day 9)
After awakening at 8:31 UTC, the crew set to work preparing to release Hubble from the payload bay of Atlantis. Using the shuttle's robotic arm, McArthur grappled Hubble at 10:45 UTC, and lifted it out of the orbiter's payload bay to prepare for the release. Good and Massimino were standing by ready to perform a spacewalk in the event that something went wrong during the telescope's deployment. After working through the checklist to prepare the telescope for release, managers on the ground gave the go to Altman to release Hubble, and at 12:57 UTC, McArthur successfully released the telescope as the vehicles flew over Africa. Performing a small separation burn, Johnson backed the orbiter away from the telescope, and Altman called down to managers on the ground confirming the deployment of Hubble. Commending the crew, Altman said "And Houston, Hubble has been released, it's safely back on its journey of exploration as we begin steps to conclude ours. Not everything went as we planned, but we planned a way to work around everything and with the whole team pulling together... we've been able to do some incredible things. And now Hubble can continue on its own, exploring the cosmos, and bringing it home to us as we head for home in a few days. Thank you." Hubble's new equipment and upgraded systems would be tested for several months prior to resuming operation, but if all tests are successful, operation of the telescope would resume in early September.

Following the separation burn, the crew set to work performing the standard late inspection of the thermal protection system of the orbiter. Using the robotic arm, McArthur, Altman, and Johnson worked through the procedures to inspect the wing leading-edge panels, reinforced carbon-carbon nose cap, and heat shield tiles. After evaluating the weather reports, managers on the ground slightly refined the schedule for landing, opting to bring the shuttle home one orbit early to try to avoid the possibility of showers that would prevent a landing on Friday. The new landing opportunity would bring the crew home at 10:01 am EDT.

20 May (Flight day 10)
After a busy week servicing Hubble, the crew of Atlantis had the majority of the day off, giving them time to rest and prepare for landing. They took their traditional on-orbit crew portrait, and spoke with reporters from around the world in a news conference. The crew also had the opportunity to speak with the Expedition 19 crew on board the International Space Station, in a conference call routed through satellites. The station crew congratulated them on a very successful mission, and the crew of Atlantis expressed their gratitude to the station crew for all the work they do during their long duration stays on the station.

The Spaceflight Meteorology Group at Johnson Space Center was predicting less than favorable weather for Friday's landing, so managers asked the crew to power down some non-critical systems to help conserve power, in the event that the orbiter is not able to land until Saturday.

After evaluating the imagery sent down from the late inspection, the ground team officially cleared the orbiter's thermal protection system for re-entry. Initially, NASA had planned on releasing Endeavour from its stand-by status following the late inspection, but managers on the ground decided to wait until Atlantis had performed the de-orbit burn before standing down the STS-400 rescue mission officially.

Before going to sleep, the crew took a phone call from President Barack Obama, who congratulated them on their successful mission, joked with them, asking if they could see his house in Chicago, and expressed his pride in the crew. Obama told the crew, "Like a lot of Americans, I've been watching with amazement the gorgeous images you've been sending back, and the incredible repair mission you've been making in space," he said. "I think you're providing a wonderful example of the kind of dedication and commitment to exploration that represents America and the space program generally. These are traits that have always made this country strong, and all of you personify them."

21 May (Flight day 11)
The crew spent the day in preparations for Friday's landing. After working through their post-sleep activities, Altman, Johnson and McArthur performed a check-out of the flight control surfaces, performed a reaction control system hot-fire, and went through communications checks with managers on the ground. The rest of the crew worked to stow away items that were used during the mission. The crew held a deorbit preparations briefing with the ground teams, and Altman and Johnson worked with the simulator on board to run through a series of landing simulations.

In the afternoon, the crew became the first shuttle crew to ever testify live from orbit in a United States Senate hearing. Barbara Mikulski, Chairman of the Senate Appropriations Committee, Subcommittee on Commerce, Justice, Science and Related Agencies, and former astronaut Senator Bill Nelson of Florida, spoke with the crew about the importance of spaceflight and the repair of Hubble. The first person to give testimony from space was John L. Phillips, who testified before the House Science Committee, Subcommittee on Space and Aeronautics in June 2005 while a member of Expedition 11 on board the International Space Station. The crew of Atlantis later spoke with reporters from the major networks CNN, ABC, NBC, CBS, and FOX before going to sleep.

While the weather in Florida continued to look grim for a landing Friday, managers on the ground advised the crew that they would proceed with deorbit preparations as planned, and see if the weather cleared up in the morning. NASA managers stated that for Friday, they would focus on a KSC landing for Friday, not activating any of the backup sites, but if the weather was not favorable for a Friday landing, Edwards Air Force Base could be activated on Saturday. Atlantis has enough consumables to stay in orbit until Monday.

Also late on Thursday, managers officially released Endeavour from its stand-by state, as Atlantis was cleared of any damage to its heat shield and was in good shape to return to Earth.

22 May (Flight day 12)
As the crew worked through the procedures and checklists for entry on Friday, the managers on the ground closely examined the weather patterns around Florida, which were less than favorable. The crew was advised that there were low clouds and thunderstorms, both conditions that violated landing criteria, so managers waived the first opportunity. A second opportunity was also not taken, as the weather had not improved. Entry Flight Director Norm Knight called up Edwards Air Force Base shortly after the decision to delay to Saturday was made, which would give the crew a total of six Saturday landing opportunities, three at each location.

23 May (Flight day 13)
The crew of Atlantis had six possible landing opportunities on Saturday. Managers evaluated the best three opportunities of the day to try bring the orbiter home. Saturday's first landing opportunity at Kennedy Space Center was waived due to poor weather forecasts, and observed weather violations for the landing criteria. After further evaluating weather patterns around Florida, managers on the ground chose to waive the second opportunity as well, and wait one more day to attempt to get the orbiter into Florida on Sunday. Weather in California had excellent forecasts, so if the attempts on Sunday to land in Florida were not successful, the shuttle would be able to land at Edwards Air Force Base without weather being an issue.

24 May (Flight day 14, landing)
The Atlantis crew had two Florida return opportunities for the day, as well as two for a California landing, giving the managers time to evaluate the weather and use California if necessary. After choosing to pass on the first opportunity for KSC and evaluate the second, managers on the ground decided that the weather in Florida was too dynamic to risk bringing the orbiter in, and opted to land at Edwards Air Force Base instead. The de-orbit burn was initiated at 14:24 UTC, a burn of the shuttle's engines that brought it out of orbit to begin the orbiter's reentry into the Earth's atmosphere. Atlantis successfully landed at Edwards Air Force Base on Runway 22 at 8:39 am PDT after 197 orbits in space and a distance of approximately 5.2 million miles.

After working through the checklists to safely power down the orbiter, the crew performed the traditional walk-around of the shuttle and met with employees from NASA. Speaking briefly to the press following the walk around, Altman joked, "I didn't realize it was going to be so hard to get back to the Earth! We're all thrilled to have the mission complete."

During the post-landing briefing, Associate Administrator for Space Sciences Ed Weiler declared the mission a total success, and after noting the rocky road that it took to get the mission completed, said he considered the mission to be Hubble's Great American Comeback story, chapter two.

""This mission...was canceled January 16, 2004, if you'd have told me on that day I'd be sitting here five years later with a totally successful five-EVA mission, with a brand new Hubble once again that will probably operate well into the third decade of its life, I wouldn't have bet you a penny. But Hubble is the great American comeback story, chapter two." – Ed Weiler"

Post landing
Following standard post-landing processing at Edwards Air Force Base, Atlantis was lifted into the air using the Mate-DeMate device, and attached to the top of a modified Boeing 747, called a Shuttle Carrier Aircraft (SCA) for its return flight to Florida. After departing California on June 1, the flight made an overnight stop at Biggs Army Airfield in El Paso, Texas, and on June 2 made stops in San Antonio, Texas, and Columbus, Mississippi to refuel. After performing a flyby of the coast, the SCA landed at Kennedy Space Center at 6:53 p.m EDT on June 2, 2009. One of the heavier return flights, Atlantis was still carrying the cargo from the mission in the payload bay, and weighed approximately one quarter of a million pounds. Combined with the 747, the total weight of the vehicle was approximately six hundred thousand pounds. Atlantis was removed from the SCA and towed to the Orbiter Processing Facility late June 2.

Extra-vehicular activity
Five back-to-back EVAs were planned for the mission. Spacewalks one through four were originally scheduled to last six hours, thirty minutes, while the fifth spacewalk was scheduled to last five hours, forty-five minutes. All five EVAs were conducted successfully, for a total time in EVA activity of thirty-six hours, fifty-six minutes.

Wake-up calls
NASA began a tradition of playing music to astronauts during the Gemini program, which was first used to wake up a flight crew during Apollo 15. Each track is specially chosen, often by their families, and usually has a special meaning to an individual member of the crew, or is applicable to their daily activities.

Contingency mission
STS-125 was the only planned shuttle mission after the Columbia accident to be launched into a low-inclination orbit that did not allow rendezvous with the International Space Station. Due to the inclination and other orbit parameters of Hubble, Atlantis would have been unable to use the International Space Station as a safe haven in the event of structural or mechanical failure. To preserve NASA's post-Columbia requirement of having shuttle Launch On Need (LON) rescue capability, STS-400 was the flight designation given to the Contingency Shuttle Crew Support (CSCS) mission which would have been flown by Endeavour in the event Atlantis became disabled during STS-125. After Atlantis performed the late inspection and was cleared for re-entry, Endeavour was officially released from stand-by status on Thursday, 21 May.