Changes to the show included perfecting the uniform (such as putting badges in the right place, and making sure actors wore their hats inside and outside) and helping with set details (including adding stock numbers on grease barrels that appear in the background).

It even meant putting some cast members through several days of a "mini boot camp" in El Paso.

The actors stayed in barracks, wore uniforms, did basic training, and underwent surprise checks for "contraband" such as books, cellphones, laptops and candy. Some of the cast members were even shunned for not flushing their toilets.

The improvements in accuracy didn't make for a hit. The first of the season's 13 episodes averaged just 2.4 million viewers and got a weak rating of 0.7 in the advertiser-desired 18-to-49 demographic.

PHOTOS: TV shows and their spinoffs

Military members and their families who were not pleased with the inaccuracies took to social media to complain.

A Facebook page, "Petition to Cancel TV Show Enlisted," reads: "This tv show is an insult to say the least to all military personnel. It satirizes our way of life and has no place on Fox or any other tv channel."

Biegel and Royce said Twitter was also full of people bashing the pilot.

So they took to social media to turn the show around.

"I probably contacted at least 200 military people on Twitter over direct message," Biegel said. "I would say, 'Hey, my name is Kevin. I created the show. Please give it another chance.'"

"It was a matter of going through every medium — blogs, podcasts, websites — to get in there and explain where we're coming from," Royce added.

After several episodes, the creators said their outreach effort and changes to fix the show have helped.

Fox officials said the show now has an average of 3.1 million viewers and a rating of 1.2 in the 18-to-49 demographic.

PHOTOS: Families that changed TV 

The show's Facebook page has just over 60,000 "likes," and the Twitter account has almost 7,000 followers.

People have used those social media sites to comment on the show's progress and suggest further changes.

"Really glad the show's getting better as we go along," one Facebook fan commented, but then criticized the show for featuring female soldiers wearing earrings.

The "Enlisted" Facebook page replied: "Good eye, soldier! We appreciate it!"

Though Fox has not announced whether the show will be renewed, those involved remain hopeful.

"We really believe in this show and think it deserves a second season," Davis said.

saba.hamedy@latimes.com

[Updated, 2:04 p.m. March 26: An earlier version of this article omitted the complete titles for Kevin Biegel and Mike Royce.]

-----------------------------

'Enlisted'

Where: Fox

When: 9 p.m. Friday

Rating: TV-14-DL (may be unsuitable for children under the age of 14 with advisories for suggestive dialogue and coarse language)