Arduino is fine when connected to computer but not when on battery

Tried that earlier and a similar thing happened but it wasn't as bad, my friend has a similar set up and his works fine