An automotive battery manufacturer is closing its Auburn Hills and Midland sites, with 324 people to lose their jobs.