LOS ANGELES (AP) - NASA launched a spacecraft Tuesday night on a mission to smash into an asteroid and test whether it would be possible to knock a speeding space rock off course if one were to threaten Earth.

The DART spacecraft, short for Double Asteroid Redirection Test, lifted off from Vandenberg Space Force Base atop a SpaceX Falcon 9 rocket in a $330 million project with echoes of the Bruce Willis movie “Armageddon.”

If all goes well, the boxy, 1,200-pound (540-kilogram) craft will slam head-on into Dimorphos, an asteroid 525 feet (160 meters) across, at 15,000 mph (24,139 kph) next September.

“This isn't going to destroy the asteroid. It's just going to give it a small nudge,” said mission official Nancy Chabot of Johns Hopkins Applied Physics Laboratory, which is managing the project.

Dimorphos orbits a much larger asteroid called Didymos. The pair are no danger to Earth but offer scientists a better way to measure the effectiveness of a collision than a single asteroid flying through space.

Dimorphos completes one orbit of Didymos every 11 hours, 55 minutes. DART's goal is a crash that will slow Dimorphos down and cause it to fall closer toward the bigger asteroid, shaving 10 minutes off its orbit.

The change in the orbital period will be measured by telescopes on Earth. The minimum change for the mission to be considered a success is 73 seconds.

The DART technique could prove useful for altering the course of an asteroid years or decades before it bears down on Earth with the potential for catastrophe.

A small nudge “would add up to a big change in its future position, and then the asteroid and the Earth wouldn't be on a collision course,” Chabot said.

Scientists constantly search for asteroids and plot their courses to determine whether they could hit the planet.

“Although there isn't a currently known asteroid that's on an impact course with the Earth, we do know that there is a large population of near-Earth asteroids out there,” said Lindley Johnson, planetary defense officer at NASA. “The key to planetary defense is finding them well before they are an impact threat.”

DART will take 10 months to reach the asteroid pair. The collision will occur about 6.8 million miles (11 million kilometers) from Earth.

Ten days beforehand, DART will release a tiny observation spacecraft supplied by the Italian space agency that will follow it.

DART will stream video until it is destroyed on impact. Three minutes later, the trailing craft will make images of the impact site and material that is ejected.