I just replaced both of my batteries last night on my '03 GMC (original Delco's went 6+ years!!). One of the old bats (right side) had a dead cell, so when I pulled the left side bat, there wasn't enough juice to run keyless and my radio clock reset, even though I was doing one bat at a time to avoid stuff like this. Anyway, I didn't have the problem with the codes that you experienced. My truck was driven to the auto parts place where I did the battery swap in the parking lot. If your truck never started (but cranked slowly) when the old bats were dead, maybe the low voltage caused the codes and it just needed a complete ign. cycle to say 'all is good'?
BTW, I apparently had a dead cell on the right and a lame left battery for a while because I don't remember the motor ever cranking as fast as it does with the 2 new bats!!
Unfortunately, new Delco's were $126 ea and new Autolites were $85. Delco's had a 50 month full replacement (compared to 24 mo for the Autolites) but the Delco's overall warranty (pro-rated portion) was a year or so shorter than the autolite. I couldn't justify 50% more $ for the delco's even given the longer full replacement warranty and that the OEM units lasted so long. Hopefully I won't live to regret this.
------------------------------------------------------
Courtesy is free, Respect must be earned.
------------------------------------------------------
2003 GMC CCSB D/A. Stock except for GY LT285/75R16 MTR tires
Frequently seen tandem-towing a Keystone Laredo 30BH and a 'custom' dirt-bike trailer full of Honda bikes for the family in and around Michigan.