Check Engine light comes on and RPM starts to decrease on 1993 Subaru Impreza

Hi, I have a Subaru Impreza (L) 1993 and about two days ago i started seeing the check engine light flash momentarily in the dashboard and then it would go away. And in the evening of that day while dropping off my friend at home, the light stayed on, and suddenly the check engine, oil, battery and power lights came on and the brakes started to apply by themselves, and when i came to a complete stop the RPM gauge dropped to 0 and the car turned off. I turned it back on and it was fine.
And this morning, the light was flashing again (but the car didn't stall).

I haven't taken it to a shop yet, but i want to say its something electrical (battery maybe?) but im not sure.

What could be causing this?

- Sal

Asked by for the 1993 Subaru Impreza
Hey Sal,
There are many possibilities. The next step is to retrieve the diagnostic trouble codes from the all the control modules and with that information, a diagnostic approach can be determined. Until then, it would be purely a guess, which wouldn't serve much purpose.
Once you get all the codes, post them here and we can give you a much better idea as to what is happening.
Good Luck!