This image provided by NASA-TV shows the cosmic ray detector just prior to being attached to the International Space Station Thursday May 19, 2011. The $2 billion Alpha Magnetic Spectrometer was delivered by space shuttle Endeavour. (AP Photo/NASA)

Endeavour's astronauts accomplished the No. 1 objective of their mission Thursday, installing a $2 billion cosmic ray detector on the International Space Station to scan the invisible universe for years to come.

The space fliers used a pair of robot arms to remove the Alpha Magnetic Spectrometer from the shuttle, then hoist it onto the sprawling framework on the right side of the station.

The instrument - which has a 3-foot magnet at its core - is the most expensive piece of equipment at the orbiting lab and certainly the most prominent scientific device. It will search for antimatter and dark matter for the rest of the life of the space station, and hopefully help explain how the cosmos originated.

Nobel Laureate Samuel Ting, the principal investigator, personally relayed his thanks from Mission Control. He's worked on the project for 17 years and fought to have it placed back on the shuttle, when its flight was suspended several years ago.

"This has been a very difficult experiment, and I think in the next 20 to 30 years, nobody will be able to do such a thing again," Ting told the astronauts. "I hope together with you, we will try to make a contribution to a better understanding of our universe."

Back at Mission Control, meanwhile, engineers continued to analyze several areas of damage on Endeavour's belly. Thermal tiles were gouged and nicked during Monday's liftoff, the second-to-last for the shuttle program. Some of the slashes are as much as 6 inches long and 2 inches wide.

NASA wants to make certain the shuttle is safe to come home in two weeks.

The damage was spotted in photos snapped by the space station crew just before Endeavour docked Wednesday. The shuttle performed a slow backflip for the cameras, a customary procedure put in place after shuttle Columbia disintegrated as it re-entered Earth's atmosphere in 2003.

Mission Control may ask shuttle commander Mark Kelly and his five crewmates to take a closer look at the gouges this weekend, using a laser-tipped inspection boom.

Kelly's wife, U.S. Rep. Gabrielle Giffords, underwent more surgery Wednesday, just two days after seeing her husband blast into orbit. Doctors in Houston put in a plastic implant to replace part of her skull that was removed following the Jan. 8 shooting rampage in Tucson, Ariz., that left six dead and 13 injured.

In a TV interview following the spectrometer work, Kelly said his wife was doing really well and her neurosurgeons were pleased. He said it didn't make sense to hold up the surgery until he got back; doctors wanted to do it Wednesday.

Kelly is keeping abreast of her condition through family members, using the space station's Internet phone. His identical twin brother Scott also is an astronaut.

When asked what personal trinkets the crew took up, Kelly pulled off the turquoise wristband he's worn for months - bearing the name "Gabby," a peace symbol and a heart. Two other astronauts pulled similar bracelets from their wrists, and the three bands floated before them.

Kelly and his crew will remain at the space station until May 29. Two of the astronauts will venture out Friday on the first of four spacewalks to perform some station maintenance.

Endeavour will conclude its final voyage with a landing on June 1.

NASA is shutting down its shuttle program this summer after 30 years, to focus on interplanetary travel. One more mission remains, by space shuttle Atlantis in July.

The space station will continue to operate until at least 2020, with Americans hitching rides on Russian Soyuz capsules until private U.S. companies can take over the job.

The Alpha Magnetic Spectrometer, better known by its acronym AMS, may well vindicate the scientific purpose of the space station, according to astronauts, researchers and others.

The international team of 600 scientists is led by Ting, a physicist at the Massachusetts Institute of Technology.

"I'm sure that Professor Ting and his group have been holding their breath. You guys can all start breathing again now," astronaut-scientist Gregory Chamitoff said once the 7-ton device was installed. It took Chamitoff and his crewmates two extra hours to complete the operation.

Ting said the spectrometer will be checked over the next couple of days, before it begins collecting data in earnest. The magnetic field generated by the instrument will bend the path of incoming cosmic particles and eight state-of-the-art detectors will try to identify them in the nanoseconds it takes to travel through the magnet.

The project has been in the works since 1994, and Ting noted there's no rush now.

"Do it very carefully and do it slowly, make sure everything is correct," he said Wednesday.

©2011 The Associated Press. All rights reserved. This material may not be published, broadcast, rewritten or redistributed.