(CNN) -- Alone in the darkness beneath layers of rubble, Dan Woolley felt blood streaming from his head and leg.

Then he remembered -- he had an app for that.

Woolley, an aid worker, husband, and father of two boys, followed instructions on his cell phone to survive the January 12 earthquake in Haiti.

"I had an app that had pre-downloaded all this information about treating wounds. So I looked up excessive bleeding and I looked up compound fracture," Woolley told CNN.

The application on his iPhone is filled with information about first aid and CPR from the American Heart Association. "So I knew I wasn't making mistakes," Woolley said. "That gave me confidence to treat my wounds properly."

Trapped in the ruins of the Hotel Montana in Port-au-Prince, he used his shirt to bandage his leg, and tied his belt around the wound. To stop the bleeding on his head, he firmly pressed a sock to it.

Concerned he might have been experiencing shock, Woolley used the app to look up what to do. It warned him not to sleep. So he set his phone alarm to go off every 20 minutes.

Once the battery got down to less than 20 percent of its power, Woolley turned it off. By then, he says, he had trained his body not to sleep for long periods, drifting off only to wake up within minutes.

Woolley's job keeps him tech savvy. He oversees interactive projects for the Christian child advocacy organization Compassion International in Colorado Springs, Colorado.



CNN iReport: Looking for loved ones in Haiti

With his injuries tended to, he wrote a note to his family in his journal: "I was in a big accident, an earthquake. Don't be upset at God. He always provides for his children even in hard times. I'm still praying that God will get me out, but he may not. But even so he will always take care of you."

The journal is stained with his blood.

After more than 60 hours, Woolley was pulled from the rubble.

"Those guys are rescue heroes," he said of the crew that pulled him out.



Interactive map of where to find aid, hospitals in Haiti

His colleague David Hames has not been found. The two had been standing together when the earthquake struck and the Hotel Montana crumbled. They were making a film about poverty in Haiti and had just gotten back to the hotel, heading to the elevator in the lobby.

"Then all of a sudden just all craziness broke loose," Woolley said. "Convulsions of the ground around us, the walls started rippling and then falling on us. [Hames] yelled out, 'I think it's an earthquake!' I looked for someplace safe to jump to and there was no safe place."

When the shaking stopped, Woolley couldn't see. And his friend was not with him.

He turned on the focus light of a camera he was wearing around his neck, but he didn't have his glasses. "So I actually took some pictures and would look at the back of the lens of the camera and saw in one of those pictures the elevator that I ended up hobbling over to. And that became my safe place."

Once in the elevator, he used the app -- called "Pocket First Aid & CPR" from Jive Media -- to tend to his injuries. Woolley said his phone "was like a high-tech version of a Swiss Army knife that enabled me to treat my own injuries, track time, stay awake and stay alive."

Woolley heard voices of some other people trapped nearby, and they spoke with each other.

"About a day, maybe day and a half in, we heard rescuers, and they had a list of our names at that point, because they were able to talk to one of the people we were talking with. And so then it seemed like, OK, this is going to happen, we're actually going to get rescued.

"But then it just took a long time and there were times where I didn't hear anything or I'd hear drilling in a far part of the building and just didn't get any reassurance they were still coming for me," Woolley said.

"The scene outside was a lot more chaotic and less simple than I imagined in my head. ... But eventually they came for me and did an amazing rescue."

Back home now in Colorado Springs with his wife Christina and children Josh, 6, and Nathan, 3, Woolley said he's grateful to God for getting him through the ordeal.

"Happiness is a morning with ... family, filled with Legos, kissing boo-boos and normalcy."