For decades, Americans have stood for the national anthem and then sat down for a ballgame. From big-city stadiums to small-town high school fields, those broad stripes and bright stars are the expected musical preamble to our ballgames.

Today the anthem is at the center of an angry national debate. Some believe the melody means respect for the fallen among our military and police. Others believe it means the entirety of the American experience. The answer often depends on the ear of the beholder.

Colin Kaepernick, then of the San Francisco 49ers, began a protest movement in the NFL last year that used the anthem as a moment of maximum impact to call attention to social injustice. Last week, with characteristic bombast, President Trump called for firing players — he called them SOBs — who protest during the anthem.

More:Fire chief directs racial slur at Steelers coach Mike Tomlin on Facebook

More:Pat Tillman's widow: Don't politicize Pat in effort to divide

More:NFL is winning in fight against President Trump

How did the dawn’s early light and twilight’s last gleaming become so politicized?

“National anthems are political,” Marc Ferris tells USA TODAY Sports. He is the author of Star-Spangled Banner: The Unlikely Story of America’s National Anthem. And he knows the history of how our anthem, born of war, became intertwined with our sporting life.

“Sports are a kind of bloodless warfare,” Ferris says, “a sort of war without death.”

The song is about a battle in the War of 1812. The first documented time that it was played at an American sporting event came at a baseball game in 1862, during the Civil War. The tradition of playing it at sports events got a dramatic boost at the 1918 World Series, during World War I. And the tradition of playing it before games was popularized during World War II.

“We’re a patriotic country and we’re different from the rest of the world in that respect,” Ferris says. “As we grew and as we prospered, people wanted to show their patriotism.”

Francis Scott Key wrote the song in 1814 and it became the nation’s de facto anthem not long after. Congress made it official in 1931. World War I vets had been lobbying for it for years.

Ferris says that in one respect Yankee Doodle Dandy should be the national anthem because it dates to the nation’s roots in the Revolutionary War. “But the Star-Spangled Banner is a better piece of music,” he says. “It’s got gravitas. It’s got history. It’s got emotional resonance.”

And bombs bursting in air. North and South wrestled over which side could claim the song during the Civil War.

“The North won the tug of war,” Ferris says. “The irony is that the South’s anthem, Dixie, was written by an anti-slavery Northerner whereas the Star-Spangled Banner, the anthem of the North, was written by a slave-holding Southerner whose family supported the Confederacy” long after Key died in 1843.

Key's song was played at some baseball games in the 1890s, often with great pomp, Ferris says, but the World Series in 1918 offered a star-spangled moment. Babe Ruth’s Boston Red Sox opened in Chicago against the Cubs. The game came 17 months — and 100,000 American deaths — after the U.S. entered the war to end all wars. During the seventh-inning stretch, a military band spontaneously played the country’s still-unofficial anthem.

Red Sox third baseman Fred Thomas, on furlough from the Navy, saluted. Other players put hands over hearts. The crowd, already on their feet to stretch, began to sing along. The New York Times reported the song’s final bars were met by “thunderous applause and rent the air with a cheer that marked the highest point of the day’s enthusiasm.”

When the Series moved to Boston, the Red Sox played the song during pregame festivities and paired it with the introduction of wounded soldiers. Ferris credits the theatrical move to Red Sox owner Harry Frazee. “He thought, ‘I’m an impresario, I’ll show those Midwesterners in Chicago how it’s done,’ ” Ferris says.

The song did not yet catch on at all games for the simple reason that owners didn’t hire bands except for big events like the World Series or Opening Day. Sound systems, in place by World War II, changed that.

“The anthem was heard everywhere” during the second world war, Ferris says. “Before the opera, before the movies, before the theater.”

And, of course, before all manner of sports. Most teams continued to play the anthem in the surge of postwar patriotism. Ferris says the Cubs stopped playing it after the war but picked it up again in 1967, during the Vietnam war, and have played it since.

Amid the upheaval of Vietnam, NFL Commissioner Pete Rozelle enforced a policy that players stand at attention during the anthem, with helmets tucked under their arms. They were not to talk, chew gum or move their feet.

The government cannot restrict speech under the First Amendment. Employers can. Today’s “owners could say to the players, ‘If you take a knee, you’re gone,’ ” Ferris says. “But of course they won’t. They want to win football games.”

The anthem is played so often at games that it can sometimes seem perfunctory. That will clearly not be the case for the foreseeable future. Ferris is fine with that.

“We are actually debating real issues,” he says. “We are having an adult discussion and that is great, as long as it’s civil.”