Gladys KnightThe Secret White House Project

3/23/2012 2:15 AM PDT BY TMZ STAFF

Gladys Knight is pulling double duty ... 'cause in between training sessions for "Dancing with the Stars," TMZ has learned Knight is also working on a top secret scripted TV show.

Sources close to production tell us ... Knight has been cast to star in a show called "The First Family" ... about a fictional President of the United States who's juggling work with his family life. We're told Gladys is playing the President's mother.

Sources connected to Gladys tell TMZ ... the Motown legend is working extremely hard to handle both gigs ... and producers on both shows are being very flexible to accommodate the star.

We're told the sitcom is already garnering interest from a major network ... which has made it clear they want to rush production to capitalize on Knight's "Dancing" momentum.

We spoke with Byron Allen -- the Executive Producer of "First Family" -- who tells us, "Gladys is truly an American treasure and we're excited to work with her."