Ok, it was the voltage regulator. I bought a new one and now it's all working correctly. Thanks for the help.