Maryland Gov. Martin O'Malley. (AP Photo/Patrick Semansky)

Maryland Gov. Martin O’Malley got a chance to talk Friday night about one of his favorite subjects — Baltimore’s pivotal role in the War of 1812 — during an appearance at a Democratic dinner in New Hampshire.

O’Malley (D) was booked as the featured speaker at an annual Flag Day Dinner, hosted by the Manchester Democrats.

The event provided an opportunity for O’Malley, a former Baltimore mayor, to recount the story of Francis Scott Key writing “The Star-Spangled Banner” after the British had been repelled and he saw the U.S. flag still flying over Fort McHenry. O’Malley referred to the War of 1812 as “the second war of American independence.”

“I would submit to you that it was in that second war of independence that we came to truly appreciate our American interdependence, the fact that we need each other, the fact that we’re all in this together,” O’Malley said in his remarks.

For O’Malley, who is preparing for a possible White House bid, Friday’s speech was the first of two scheduled appearances in early presidential nominating states within a week. Next Friday and Saturday, he plans to be in Iowa for state party events.

O’Malley has said he is moving ahead with preparations for a possible 2016 presidential bid and can’t wait for Hillary Rodham Clinton to announce whether she is running — a decision not expected before the end of the year. Aides stress O’Malley has made no decision about moving forward, however.

As he mulls his political future, O’Malley has become a regular on the Democratic speaking circuit, most often traveling to states where fellow party members are on the ballot in statewide races. He did not deliver his standard speech Friday, aides said, in part because New Hampshire Democrats had already heard it: O’Malley was last in the Granite State in November for a Jefferson-Jackson dinner.

Aides said Friday’s return visit resulted from an invitation from Raymond Buckley, chairman of the state party in New Hampshire. Buckley was recently in Maryland, attending the Maryland Democratic Party’s annual gala, held last month in Upper Marlboro, at which New Hampshire Gov. Maggie Hassan (D) was the guest speaker.

Friday’s dinner commemorated Flag Day, which is actually Saturday. The topic of O’Malley’s speech was a familiar one for him, particularly with Maryland in the midst of a prolonged bicentennial celebration of the War of 1812. (The Battle of Baltimore and Key’s writing of what became the national anthem did not occur until 1814.)

Next weekend, O’Malley is scheduled to attend the Iowa Democratic Party’s Hall of Fame celebration on June 20 and then be a speaker at the party’s state convention the next day.

Aides say O’Malley’s travel to Iowa will be his first time in the state since 2012, when he was the keynote speaker at U.S. Sen. Tom Harkin’s annual steak fry fundraiser.