A battery light that comes on while driving (not just at startup) usually points to the charging system, not the battery itself.
Comes on while driving, not at startup
Electronics seem to dim slightly
The alternator has stopped fully recharging the battery while you drive.
A slipping belt can't spin the alternator fast enough to keep up.
A loose or corroded connection can mimic a charging fault.