In a nutshell, yes, a low battery can cause you trouble codes where none should exist. Low batteries can cause all kinds of lights to flash.
Before you buy a new battery, though, you should make sure it is actually at issue. Charge the battery and see if it will handle a charge. If it won't accept (and keep) a charge, then restart your vehicle making sure you clear the codes at some point during the process. If the codes come back, then you have other issues you need to attend to.
If you're able to recharge the battery and get it started, check your alternator to see if it is functioning correctly. If you put a multimeter on the battery while it's running, observe the voltage. It should be steady state at around 13.5-14.1 vdc. If the voltage is continuously dropping, it's the alternator at fault not the battery (could also be the battery is bad, but we're looking at the alternator right now).
If the battery won't hold a charge, then replace it. At this point you know it's bad, but it's better to test it rather than drop a couple hundred bucks without really knowing.