For the first time in almost two years, NASA has re-established its connection with a long-lost spacecraft.

On Sunday, NASA's 22 months of attempts to get back in touch with STEREO-B paid off when the Deep Space Network locked onto the satellite's signal.

While this is great news for the space agency, STEREO-B isn't out of the woods yet.

SEE ALSO: A comet got vaporized by the sun and a spacecraft watched it happen

Mission controllers still need to figure out if the spacecraft is healthy and capable of carrying on with its solar research after being unable to communicate with its home planet for such a long time, but the fact that it's in touch at all is promising.

It has been a long road to recovery for STEREO-B.

The probe and its still-functioning sibling, STEREO-A, are tasked with keeping an eye on the sun simultaneously, giving scientists a view of the entire star with their unique orbits. This kind of data allows researchers to look at our closest star in unprecedented detail when both crafts are working correctly.

The orbits of STEREO-A and STEREO-B. Image: NASA

The trouble started on Oct. 1, 2014 when NASA first lost contact with STEREO-B after a test of some of the spacecraft's systems didn't go as planned.

STEREO-A and B were only expected to function in space until 2008, but both lasted much longer. This long life is a huge boon for researchers, but it comes with its own set of challenges.

Because of the orbits of the spacecraft, scientists realized that at some point both would be in a months-long period of communications blackout with Earth because of the sun's interference.

“The sun emits strongly in nearly every wavelength, making it the biggest source of noise in the sky,” Dan Ossing, mission operations manager for STEREO, said in a NASA statement.

“Most deep space missions only have to deal with sun interference for a day or so, but for each of the STEREO spacecraft, this period lasted nearly four months.”

STEREO-A and B both come equipped with a "command loss timer" that forces it to reboot if the craft lose touch with Earth for more than 72 hours. When scientists lost touch with STEREO-B, they were in the process of testing this timer in anticipation of the communications blackout.

Although STEREO-A's test went smoothly, STEREO-B didn't power itself back on properly after operators stopped communicating with it. NASA did receive a signal, but it was more faint than expected and then it faded.

Since then, scientists have been trying to gain control of the spacecraft and help charge its batteries, giving it a chance to get in touch with Earth. Then, mission managers could get it into the right position again.

Sunday's communication could signal that the spacecraft is coming back to life.

Mission controllers have been using the Deep Space Network to try to get in touch with STEREO-B ever since that day in October 2014, and it finally looks like that persistence paid off.