Percy Harvin's migraine problems may be over.

According to a report by NBCSports.com, Harvin says doctors diagnosed him with sleep apnea after his hospital stay following a scary incident at a Minnesota Vikings practice Aug. 19.

Harvin said doctors believe the disorder was responsible for the headaches that caused Harvin to lose consciousness and leave the practice in an ambulance, according to the NBCSports.com report.

Harvin said that four days after his hospital visit, doctors gave him an overnight sleep test.

According to Harvin, his heart stopped beating eight times during the test for up to 10 seconds at a time. Harvin said doctors suspected the wideout wasn't getting enough oxygen while sleeping, according to the report.

Sleep apnea causes gaps in a person's breathing while sleeping.

Harvin said he uses a device that pumps air into his nose to regulate his breathing while he is sleeping in order to treat the disorder.

He told NBCSports.com that he no longer takes his migraine medication, which he blames for his August collapse.

Harvin has endured migraines for most of his life, but his episode on the practice field frightened his teammates, to the point where they called off practice after Harvin was taken to the hospital in the ambulance.

"I think by this happening it kind of lets the team know exactly how hard it is," left tackle Bryant McKinnie said. "A lot of times it doesn't take place in front of us. So now by people actually seeing it, they see it's really not a joke."

Information from The Associated Press was used in this report.