You may not have realized it, but epilepsy is not a particularly uncommon condition for dogs to have, and the treatment is generally straightforward. Diagnosing the condition, however, can be a little tricky, as this article explains.
Via the University of Guelph: "Mobile Technology Helps Diagnose Epilepsy in Dogs."
(One of our former nurses, Katie, is actually in vet school at this university right now, which is how I found the article. Hi, Katie! Thanks, Katie!)