STOP 0x0000005C or HALINITIALIZATIONFAILED ?
Usually down to bad connection to the motherboard - the 24 pin plug from PSU to motherboard.
Could come as you seem to be powering off before it boots
Next time you start tap the F8 button and select Startup repair from the menu.
If it finds nothing or doesn't boot the time after then keep doing start up repair (up to 5 times) as it can take several attempts to find and correct the problem.
None of this will have anything to do with your internet connection problem.
As far as connection problem is concerned are we talkingabout a wired or wireless signal problem?
If wireless then change the channel in the router as neighbours signals can affect it